Package: vzctl Version: 3.0.24-1 Severity: minor
vzctl makes adjustments to /etc/hosts via scripts to account for the IP-adress and hostname that has been set in the VE configuration. However, it also adjusts the entry for localhost. This is problematic if, for example, you have an alias for localhost: 127.0.0.1 localhost localhost.localdomain mysql When the vserver is restarted, the "mysql" alias is gone which causes problems for the application. The responsible code is in /etc/vz/dists/scripts/functions : 313 $1 == "127.0.0.1" { ate_localhost = 1; next; } 314 {print} 315 END { 316 if (ip == "") { ip ="127.0.0.1" } 317 if (ate_localhost && ip != "127.0.0.1") { 318 print "127.0.0.1 localhost.localdomain localhost"; 319 } 320 print comm; 321 if ((i=index(host, ".")) > 1) { 322 alias= " " substr(host, 1, i - 1); 323 if (! (alias in EXTRANAMES)) { 324 EXTRANAMES[alias] = 1; 325 } 326 } So - first is the 127.0.0.1 entry regenerated, then is the "comm" information ("# Autogenerated hostname ...") appended, and then the hostname. I do not see a reason for 127.0.0.1 to be regenerated. Usually it points at localhost, in which case the code provides no benefit. If the admin has added an alias to localhost, it will be overwritten, which can be quite annoying. I suggest contacting upstream if there is a reason for this manipulation, and if not, leave 127.0.0.1 alone by commenting line #313, perhaps with a reference to this bug report. Best regards, Stefan -- System Information: Debian Release: lenny/sid APT prefers testing APT policy: (500, 'testing') Architecture: i386 (i686) Kernel: Linux 2.6.32-trunk-686 (SMP w/1 CPU core) Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) (ignored: LC_ALL set to sv_SE) Shell: /bin/sh linked to /bin/bash Versions of packages vzctl depends on: ii iproute 20080417-1 networking and traffic control too ii libc6 2.10.2-2 GNU C Library: Shared libraries ii vzquota 3.0.12-3 server virtualization solution - q Versions of packages vzctl recommends: ii rsync 3.0.7-1 fast remote file copy program (lik -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org