OpenVZ Forum


Home » General » Support » Why umount script runs on VE start?
Re: Why umount script runs on VE start? [message #37803 is a reply to message #37802] Thu, 22 October 2009 16:56 Go to previous messageGo to previous message
cray is currently offline  cray
Messages: 11
Registered: October 2009
Junior Member
kir wrote on Thu, 22 October 2009 12:47
cray wrote on Thu, 22 October 2009 20:42
What about the -n option, I doesn't use it in both scripts.


From another topic by you I see that you have used it, see this message.


I have removed -n key, as I didn't see the mounts.

kir wrote on Thu, 22 October 2009 12:47

Quote:
exit 0 didn't help me.


host:~# vzctl start 101
Starting VE ...
VE is mounted
Adding IP address(es): 192.168.0.101
Setting CPU units: 1000
Configure meminfo: 65536
File resolv.conf was modified
VE start in progress...
host:~# vzctl stop 101
Stopping VE ...
VE was stopped
umount: /test: not mounted
umount: /test: not mounted
VE is unmounted
host:~#




here is the cat of mount/umount scripts:

cat 101.mount
#!/bin/bash
mount --bind /test /home/vz/root/$VEID/mnt

cat 101.umount
#!/bin/bash
umount /home/vz/root/$VEID/mnt
exit 0



kir wrote on Thu, 22 October 2009 12:47
What do you mean «didn't help»? Can you describe one more time what problem are you having?

Quote:
I assume that mount/umount scripts should work this way:

start VE
mount /path/from /path/to
-------------------------
umount /path/to
stop VE


They do not work this way -- mount is happening *before* CT start, while umount is happening *after* CT stop. Plus, as I described above, umount is run on start if CT is mounted.


Well, if umount script starts when the VE is stoped, so it can not unmount the path, as root directory of the VE is unmounted. Am I right?

P.S. What is CT? Is it VE (virtual environment)?

[Updated on: Thu, 22 October 2009 16:59]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: *SOLVED* OpenVZ mount script works incorrectly
Next Topic: routing tables with openvz container
Goto Forum:
  


Current Time: Sat Oct 04 20:44:59 GMT 2025

Total time taken to generate the page: 0.16835 seconds