OpenVZ Forum


Home » Mailing lists » Users » Strange mount problem
Strange mount problem [message #42930] Mon, 20 June 2011 12:26 Go to next message
Marc Peiser is currently offline  Marc Peiser
Messages: 4
Registered: June 2011
Junior Member
Hi,

I've started noticing that one of our openvz servers is doing something strange to the containers on that box, about 90% of them are now unable to do a df to show disk space, it returns nothing. I tried upgrading to the latest kernel version and still have this problem. The files are all there and everything seems to run fine apart from been able to see disk space used.

[root@va-box /]# df
Filesystem 1K-blocks Used Available Use% Mounted on
[root@va-box /]# mount
none on /dev/pts type devpts (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
[root@va-box /]#

Has anyone seen this before?

Regards,
Marc
Re: Strange mount problem [message #42958 is a reply to message #42930] Wed, 22 June 2011 12:27 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

On 06/20/2011 04:26 PM, Marc Peiser wrote:
> Hi,
>
> I've started noticing that one of our openvz servers is doing something strange to the containers on that box, about 90% of them are now unable to do a df to show disk space, it returns nothing. I tried upgrading to the latest kernel version and still have this problem. The files are all there and everything seems to run fine apart from been able to see disk space used.
>
> [root@va-box /]# df
> Filesystem 1K-blocks Used Available Use% Mounted on
> [root@va-box /]# mount
> none on /dev/pts type devpts (rw)
> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
> [root@va-box /]#

Please provide the output of the following commands (in a container):
ls -l /etc/mtab
ls -l /proc/mounts
cat /proc/mounts
cat /etc/mtab

And on the host system:
uname -a
rpm -q vzctl


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Strange mount problem [message #42963 is a reply to message #42930] Wed, 22 June 2011 15:26 Go to previous messageGo to next message
dowdle is currently offline  dowdle
Messages: 261
Registered: December 2005
Location: Bozeman, Montana
Senior Member
Marc,

----- Original Message -----
> [root@va-box /]# df
> Filesystem 1K-blocks Used Available Use% Mounted on
> [root@va-box /]# mount
> none on /dev/pts type devpts (rw)
> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
> [root@va-box /]#

As kir pointed out... if /etc/mtab is not a symlink to /proc/mounts, make it one and it'll probably work for you again.

TYL,
--
Scott Dowdle
704 Church Street
Belgrade, MT 59714
(406)388-0827 [home]
(406)994-3931 [work]


--
TYL, Scott Dowdle
Belgrade, Montana, USA
Re: Strange mount problem [message #42994 is a reply to message #42958] Mon, 27 June 2011 10:42 Go to previous messageGo to next message
Marc Peiser is currently offline  Marc Peiser
Messages: 4
Registered: June 2011
Junior Member
Hi Kir,

Here's the output you requested:

Container:
[root@va-apache /]# ls -l /etc/mtab
-rw-r--r-- 1 root root 77 Jun 17 15:53 /etc/mtab
[root@va-apache /]# ls -l /proc/mounts
lr-xr-xr-x 1 root root 11 Jun 27 12:32 /proc/mounts -> self/mounts
[root@va-apache /]# cat /proc/mounts
/dev/simfs / simfs rw,relatime 0 0
/dev/root /opt/apps-shared1 ext3 rw,relatime,data=ordered 0 0
/dev/root /opt/apps-shared2 ext3 rw,relatime,data=ordered 0 0
//172.20.40.10/F$ /opt/dataserver cifs
rw,mand,nodev,noexec,relatime,unc=\\172.20.40.10\F$,username =fileshare,uid=500,forceuid,gid=0,noforcegid,addr=172.20.40. 10,file_mode=02767,dir_mode=0777,rsize=16384,wsize=57344
0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,relatime 0 0
none /dev tmpfs rw,relatime 0 0
none /dev/pts devpts rw,relatime 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw,relatime 0 0
[root@va-apache /]# cat /etc/mtab
none /dev/pts devpts rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

Host:
[root@lnxsvr2 ~]# uname -a
Linux lnxsvr2.valuead.com 2.6.18-238.12.1.el5.028stab091.1 #1 SMP Wed
Jun 1 13:20:25 MSD 2011 x86_64 x86_64 x86_64 GNU/Linux
[root@lnxsvr2 ~]# rpm -q vzctl
vzctl-3.0.28.3-1

Regards,
Marc

On Wed, Jun 22, 2011 at 2:27 PM, Kir Kolyshkin <kir@openvz.org> wrote:
> On 06/20/2011 04:26 PM, Marc Peiser wrote:
>>
>> Hi,
>>
>> I've started noticing that one of our openvz servers is doing something
>> strange to the containers on that box, about 90% of them are now unable to
>> do a df to show disk space, it returns nothing. I tried upgrading to the
>> latest kernel version and still have this problem. The files are all there
>> and everything seems to run fine apart from been able to see disk space
>> used.
>>
>> [root@va-box /]# df
>> Filesystem           1K-blocks      Used Available Use% Mounted on
>> [root@va-box /]# mount
>> none on /dev/pts type devpts (rw)
>> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
>> [root@va-box /]#
>
> Please provide the output of the following commands (in a container):
> ls -l /etc/mtab
> ls -l /proc/mounts
> cat /proc/mounts
> cat /etc/mtab
>
> And on the host system:
> uname -a
> rpm -q vzctl
>



--
Marc Peiser
IT Matter cc
Tel : 071 678 5368
Fax : 086 602 2880
Email : marc@itmatter.co.za
Re: Strange mount problem [message #42995 is a reply to message #42963] Mon, 27 June 2011 10:45 Go to previous messageGo to next message
Marc Peiser is currently offline  Marc Peiser
Messages: 4
Registered: June 2011
Junior Member
Hi Scott,

You are correct, /etc/mtab was not a symlink. I deleted it and created
a symlink but when I restart the container it's back to a normal file
again:

[root@va-webdav /]# rm -rf /etc/mtab
[root@va-webdav /]# ln -s /proc/mounts /etc/mtab
[root@va-webdav /]# ls -l /etc/mtab
lrwxrwxrwx 1 root root 12 Jun 27 12:37 /etc/mtab -> /proc/mounts
[root@va-webdav /]# init 6
[root@va-webdav /]# got signal 15
exited from CT 233
[root@lnxsvr2 ~]# vzenter 233
entered into CT 233
[root@va-webdav /]# df -h
Filesystem Size Used Avail Use% Mounted on
[root@va-webdav /]# ls -l /etc/mtab
-rw-r--r-- 1 root root 77 Jun 27 12:38 /etc/mtab

Thanks,
Marc

On Wed, Jun 22, 2011 at 5:26 PM, Scott Dowdle <dowdle@montanalinux.org> wrote:
> Marc,
>
> ----- Original Message -----
>> [root@va-box /]# df
>> Filesystem           1K-blocks      Used Available Use% Mounted on
>> [root@va-box /]# mount
>> none on /dev/pts type devpts (rw)
>> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
>> [root@va-box /]#
>
> As kir pointed out... if /etc/mtab is not a symlink to /proc/mounts, make it one and it'll probably work for you again.
>
> TYL,
> --
> Scott Dowdle
> 704 Church Street
> Belgrade, MT 59714
> (406)388-0827 [home]
> (406)994-3931 [work]
--
Marc Peiser
IT Matter cc
Tel : 071 678 5368
Fax : 086 602 2880
Email : marc@itmatter.co.za
Re: Strange mount problem [message #42996 is a reply to message #42930] Mon, 27 June 2011 14:44 Go to previous message
Marc Peiser is currently offline  Marc Peiser
Messages: 4
Registered: June 2011
Junior Member
Anatoly,

I'm using one of the precreated centos 5 templates from about a year
ago, not 100% sure which one. Is there a easy way to tell?

The only bit I can see is this from /etc/init.d/network

rootopts=$(awk '{ if ($1 !~ /^[ \t]*#/ && $2 == "/") { print $4; }}' /etc/mtab)

Not sure if that writes to mtab or not?



On Mon, Jun 27, 2011 at 1:44 PM, Anatoly Pugachev <matorola@gmail.com> wrote:
> Marc,
>
> what Linux/OS template was used to create this container?
> You can probably grep start scripts of this Linux, to see is there's
> anything which could change /etc/mtab file?
>
> On Mon, Jun 27, 2011 at 2:45 PM, Marc Peiser <marc@itmatter.co.za> wrote:
>> Hi Scott,
>>
>> You are correct, /etc/mtab was not a symlink. I deleted it and created
>> a symlink but when I restart the container it's back to a normal file
>> again:
>>
>> [root@va-webdav /]# rm -rf /etc/mtab
>> [root@va-webdav /]# ln -s /proc/mounts /etc/mtab
>> [root@va-webdav /]# ls -l /etc/mtab
>> lrwxrwxrwx 1 root root 12 Jun 27 12:37 /etc/mtab -> /proc/mounts
>> [root@va-webdav /]# init 6
>> [root@va-webdav /]# got signal 15
>>                                 exited from CT 233
>> [root@lnxsvr2 ~]# vzenter 233
>> entered into CT 233
>> [root@va-webdav /]# df -h
>> Filesystem            Size  Used Avail Use% Mounted on
>> [root@va-webdav /]# ls -l /etc/mtab
>> -rw-r--r-- 1 root root 77 Jun 27 12:38 /etc/mtab
>>
>> Thanks,
>> Marc
>>
>> On Wed, Jun 22, 2011 at 5:26 PM, Scott Dowdle <dowdle@montanalinux.org> wrote:
>>> Marc,
>>>
>>> ----- Original Message -----
>>>> [root@va-box /]# df
>>>> Filesystem           1K-blocks      Used Available Use% Mounted on
>>>> [root@va-box /]# mount
>>>> none on /dev/pts type devpts (rw)
>>>> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
>>>> [root@va-box /]#
>>>
>>> As kir pointed out... if /etc/mtab is not a symlink to /proc/mounts, make it one and it'll probably work for you again.
>



--
Marc Peiser
IT Matter cc
Tel : 071 678 5368
Fax : 086 602 2880
Email : marc@itmatter.co.za
Previous Topic: &quot;permission denied&quot; error on CT rc.local script to add custom commands by regular
Next Topic: centos5 repo mirrors
Goto Forum:
  


Current Time: Tue Apr 30 13:47:42 GMT 2024

Total time taken to generate the page: 0.01607 seconds