Mysql [Warning] Can't create test file

526849 次阅读 by 九九 2012-07-23 | 标签:服务器 问题

啊!!这Linux就是权限流,各种权限引发的时间消耗战,搞来搞去,找来找去,最后还是在“权限”这两个字上面找到了解法~为了让数据库文件能更加的安全,我把Mysql Database的目录指向到了Home下的一个库目录,并把此目录的所有东西都给了mysql用户,执行:

#sudo chmod mysql:mysql -R xxxx

可弄了半天,还是报着

Mysql [Warning] Can't create test file

之类的错误。我找不到解法了,一路狂Google,找到了篇Blog,如下所写:

在一篇老外的帖子中找到了大概原因,大概原因是安装了SELINUX策略后,无论APACHE或MYSQL都要更改目录的权限

如果是APACHE,方法为:

# chcon -R -h -t httpd_sys_content_t /www/web/

如果是mysql,方法为:

# chcon -R -t mysqld_db_t /mysql

啊!!重新的来

#sudo service mysqld start
mysqld start [成功]

评论(27840)

massage lyon 4 To 九九 (11小时以前)

Saved as a favorite, I like your website! https://goo.gl/maps/RLPFGxUQTms

Antonio Mccray To 九九 (15小时以前)

With blackjack you play a card game against the bank. The target of you and him is for getting a hand of cards as near as possible to 21. Simpler to more then 21 you're busted as well as the same rule applies to the bank. https://sleepbrazil6.wordpress.com/?p=24&preview=true

Doretha To 九九 (15小时以前)

You actually make it seem so easy with your presentation but I find this topic to be really something which I think I would never understand. It seems too complicated and very broad for me. I am looking forward for your next post, I will try to get the hang of it!cheap nhl jerseys

spa massage lyon To 九九 (2天以前)

My partner and I stumbled over here different web address and thought I may as well check things out. I like what I see so now i'm following you. Look forward to looking at your web page repeatedly. https://goo.gl/maps/RLPFGxUQTms

institut de massage lyon To 九九 (2天以前)

Howdy! This article could not be written much better! Looking at this article reminds me of my previous roommate! He constantly kept preaching about this. I most certainly will forward this article to him. Fairly certain he will have a great read. Thank you for sharing! https://goo.gl/maps/RLPFGxUQTms

salon de massage lyon To 九九 (2天以前)

You actually make it seem so easy with your presentation but I find this matter to be actually something which I think I would never understand. It seems too complex and very broad for me. I am looking forward for your next post, I'll try to get the hang of it! https://goo.gl/maps/RLPFGxUQTms

detente massage lyon To 九九 (3天以前)

My partner and I stumbled over here by a different web page and thought I should check things out. I like what I see so i am just following you. Look forward to looking into your web page again. https://goo.gl/maps/RLPFGxUQTms

Hassan To 九九 (3天以前)

nhl cheap jerseys.Our online shop will stock the entire range of Authentic Nhl Jerseys Wholesale australia together with some fantastic discounted baseball jerseys for women,it's your pleasure to buy it with free shipping.

massage lyon spa To 九九 (3天以前)

If you are going for finest contents like I do, just visit this web site every day for the reason that it presents feature contents, thanks https://goo.gl/maps/RLPFGxUQTms

salon massage lyon To 九九 (3天以前)

Hi there everyone, it's my first visit at this web site, and piece of writing is really fruitful in support of me, keep up posting such posts. https://goo.gl/maps/RLPFGxUQTms

massage lyon croix rousse To 九九 (4天以前)

My brother suggested I might like this blog. He was totally right. This post truly made my day. You cann't imagine just how much time I had spent for this info! Thanks! https://goo.gl/maps/RLPFGxUQTms

massage lyon france To 九九 (4天以前)

Good day I am so thrilled I found your blog page, I really found you by accident, while I was browsing on Aol for something else, Anyways I am here now and would just like to say thank you for a remarkable post and a all round enjoyable blog (I also love the theme/design), I don't have time to browse it all at the minute but I have saved it and also included your RSS feeds, so when I have time I will be back to read more, Please do keep up the fantastic work. https://goo.gl/maps/RLPF

institut de massage lyon To 九九 (4天以前)

Greetings from Idaho! I'm bored to death at work so I decided to browse your website on my iphone during lunch break. I really like the information you provide here and can't wait to take a look when I get home. I'm amazed at how quick your blog loaded on my cell phone .. I'm not even using WIFI, just 3G .. Anyhow, very good blog! https://goo.gl/maps/RLPFGxUQTms

institut massage lyon To 九九 (5天以前)

Greetings! I know this is kinda off topic but I was wondering which blog platform are you using for this site? I'm getting fed up of Wordpress because I've had problems with hackers and I'm looking at options for another platform. I would be fantastic if you could point me in the direction of a good platform. https://goo.gl/maps/RLPFGxUQTms

meilleur massage lyon To 九九 (5天以前)

Your method of explaining everything in this article is in fact fastidious, every one be capable of effortlessly be aware of it, Thanks a lot. https://goo.gl/maps/RLPFGxUQTms

massage lyon france To 九九 (5天以前)

Good article. I certainly appreciate this site. Continue the good work! https://goo.gl/maps/RLPFGxUQTms

soins massage lyon To 九九 (6天以前)

That is a good tip particularly to those fresh to the blogosphere. Simple but very precise information… Thanks for sharing this one. A must read post! https://goo.gl/maps/RLPFGxUQTms

spa massage lyon To 九九 (6天以前)

I'm not sure why but this web site is loading incredibly slow for me. Is anyone else having this problem or is it a issue on my end? I'll check back later on and see if the problem still exists. https://goo.gl/maps/RLPFGxUQTms

seance de massage lyon To 九九 (6天以前)

I am extremely impressed with your writing skills as well as with the layout on your weblog. Is this a paid theme or did you modify it yourself? Either way keep up the nice quality writing, it is rare to see a great blog like this one nowadays. https://goo.gl/maps/RLPFGxUQTms

massage lyon croix rousse To 九九 (7天以前)

In fact when someone doesn't be aware of after that its up to other viewers that they will help, so here it occurs. https://goo.gl/maps/RLPFGxUQTms

PS:多打字可以减肥哦~234字以内。支持表情:


Top