Re: 200 IPs in a single VE? [message #28553 is a reply to message #28549] |
Mon, 24 March 2008 08:01 ![Go to previous message Go to previous message](/theme/ovz3/images/up.png) |
|
I don't think it will work. Maybe it works with vzctl, but not with the shell scripts, some of which are sourcing container configs. If a shell script is sourcing the file, all the subsequent assignments will overwrite the previous one, so a shell script will think this container only have one IP (the last one from the config).
Your best shot is space-separated list, as documented in man vps.conf. Shell script written by curx above does just what you want (and the fact that it uses vzctl set --save means those IPs are saved into config file.
Alternatively, you can do something like:
IPR=65.49.42 ; START=70; STOP=254; echo -n 'IP_ADDRESS="'; for dip in `seq $START $STOP`; do echo -n $IPR.$dip "" ; done; echo '"'
if you want to modify the config file directly, add the output of the above shell code to /etc/vz/conf/CTID.conf (and make sure you have removed previous IP_ADDRESS declaration from it).
Kir Kolyshkin
[Updated on: Mon, 24 March 2008 08:02] Report message to a moderator
|
|
|