I'm just wondering if I need to restart my server after editing fstab and mtab. I changed something in this file manually due to problem with awstats report.
I am using ISPConfig 3 with the help of the tutorial from howtoforge. But due to removing/deleting of some account, the configuration of fstab and mtab messed up.
I also ask this question at howtoforge forum but until now no one has answered. If you'd like to read my question please visit it here.
I tried very hard to fix the problem w/o luck.
Update:
Here's what happen to my fstab:
Before the value was (I omitted the other):
/var/log/ispconfig/httpd/mydomain.com /var/www/clients/client1/web1/log none bind,nobootwait 0 0
/var/log/ispconfig/httpd/example.com /var/www/clients/client1/web2/log none bind,nobootwait 0 0
So I changed it to the correct path:
/var/log/ispconfig/httpd/mydomain.com /var/www/clients/client1/web2/log none bind,nobootwait 0 0
/var/log/ispconfig/httpd/example.com /var/www/clients/client1/web3/log none bind,nobootwait 0 0
I also found mtab to have the same value as above that's why I edited it manually.
from:
/var/log/ispconfig/httpd/mydomain.com /var/www/clients/client1/web1/log none rw,bind 0 0
/var/log/ispconfig/httpd/example.com /var/www/clients/client1/web2/log none rw,bind 0 0
to:
/var/log/ispconfig/httpd/mydomain.com /var/www/clients/client1/web2/log none rw,bind 0 0
/var/log/ispconfig/httpd/example.com /var/www/clients/client1/web3/log none rw,bind 0 0
I edited those value because the correct path of mydomain.com and example.com should be under web2 and web3 folder respectively.
As of now the log of example.com is pointed to:
/var/www/clients/client1/web2/log
when it should be:
/var/www/clients/client1/web3/log
So I am thinking that this is because of fstab and mtab.
Please guide me how to point the log correctly to it's default directory.
I explain the scenario one by one at this link.
Best Answer
File
/etc/mtab
is maintained by the operating system. Don't edit it.File
/etc/fstab
defines what should be mounted. It is read at system start.When I add an extra disk to a system that should be mounted at system start I add it to
/etc/fstab
.To check the correctness of the updated
/etc/fstab
I use the commandmount -a
. That reads/etc/fstab
as system start, it mounts filesytems that aren'nt yet mounted.It gives an error when the mountpoint is missing or the device is missing.
To answer the question on rebooting: No, there is no need to reboot after editing
/etc/fstab
. You can testdrive withmount -a