Please change the ocurrence of the variable PASSWD to something like UPASSWD in first-boot-setup uniformly for all Squeeze templates like WordPress as reserved keywords are ignored in Squeeze.
pve-manager: 1.8-15 (pve-manager/1.8/5754)
running kernel: 2.6.32-4-pve
proxmox-ve-2.6.32: 1.8-32
pve-kernel-2.6.32-4-pve: 2.6.32-32
qemu-server: 1.1-30
pve-firmware: 1.0-11
libpve-storage-perl: 1.0-17
vncterm: 0.9-2
vzctl: 3.0.24-1pve4
vzdump: 1.2-11
vzprocps: 2.0.11-2
vzquota: 3.0.11-1
pve-qemu-kvm: 0.14.0-3
ksm-control-daemon: 1.0-5
starting init logger
INIT: version 2.88 booting
stty: standard input: Invalid argument
Using makefile-style concurrent boot in runlevel S.
Activating swap...done.
mount: permission denied
Cleaning up ifupdown....
Setting up networking....
Fast boot enabled, so skipping file system check. ... (warning).
Mounting local filesystems...done.
Activating swapfile swap...done.
Cleaning up temporary files....
Configuring network interfaces...done.
Starting portmap daemon....
Cleaning up temporary files....
Setting kernel variables ...done.
INIT: Entering runlevel: 2
stty: standard input: Invalid argument
Using makefile-style concurrent boot in runlevel 2.
mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
Starting portmap daemon...Already running..
Starting enhanced syslogd: rsyslogd.
Starting deferred execution scheduler: atd.
Starting periodic command scheduler: cron.
Starting MySQL database server: mysqld.
Checking for corrupt, not cleanly closed and upgrade needing tables..
Starting Postfix Mail Transport Agent: postfix.
generating ssh host keys
update-rc.d: using dependency based boot sequencing
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
Starting OpenBSD Secure Shell server: sshd.
Generate Wordpress Siteconfig
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
Starting web server: apache2.
startpar: service(s) returned failure: mysql_randompw ... failed!
INIT: no more processes left in this runlevel
[client]
user=root
password="admin"
update-rc.d mysql defaults 19 21
update-rc.d mysql_randompw start 20 2 .
update-rc.d urandom start 55 S . start 30 0 6 .
#!/bin/sh
### BEGIN INIT INFO
# Provides: mysql_randompw
# Required-Start: $local_fs
# Required-Stop:
# X-Start-Before: mysql
# Default-Start: 2
# Default-Stop:
# Short-Description: Generate random MySQL root password
# Description: Generate and set a random MySQL root password
### END INIT INFO
set -e
HNAME=`head -n 1 /etc/hostname|awk '{ prin2t $1; }'`
if [ "X${HNAME}" = "Xlocalhost" ] ; then
exit 0;
fi
# set HOME dir (for .my.cfg)
export HOME=/root
export USER=root
UPASSWD=`openssl rand -base64 9`
mysqladmin password "${UPASSWD}"
cat <<EOF > /root/.my.cnf
[client]
user=root
password="${UPASSWD}"
EOF
chmod 0600 /root/.my.cnf
rm -f /etc/init.d/mysql_randompw
update-rc.d -f mysql_randompw remove
pve-manager: 1.8-17 (pve-manager/1.8/5948)
running kernel: 2.6.32-4-pve
proxmox-ve-2.6.32: 1.8-33
pve-kernel-2.6.32-4-pve: 2.6.32-33
qemu-server: 1.1-30
pve-firmware: 1.0-11
libpve-storage-perl: 1.0-17
vncterm: 0.9-2
vzctl: 3.0.26-1pve4
vzdump: 1.2-12
vzprocps: 2.0.11-2
vzquota: 3.0.11-1
pve-qemu-kvm: 0.14.0-3
ksm-control-daemon: 1.0-5
dpkg -l dab
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name Version Description
+++-==============-==============-============================================
ii dab 1.1-14 Debian OpenVZ Appliance Builder
# dpkg -l dab
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name Version Description
+++-==============-==============-============================================
ii dab 1.1-12 Debian OpenVZ Appliance Builder
UPASSWD=`openssl rand -base64 9`
mysqladmin password "${UPASSWD}"
cat <<EOF > /root/.my.cnf
[client]
user=root
password="${UPASSWD}"
EOF
chmod 0600 /root/.my.cnf
rm -f /etc/init.d/mysql_randompw
update-rc.d -f mysql_randompw remove
if [ -x /sbin/insserv ] ; then
/sbin/insserv -r mysql_randompw
rm -f /etc/init.d/mysql_randompw
else
rm -f /etc/init.d/mysql_randompw
update-rc.d -f mysql_randompw remove
fi
--2011-05-20 19:15:57-- [URL]http://download.proxmox.com/debian/dists/lenny/pve/binary-amd64/dab_1.1-14_all.deb[/URL]
Resolving download.proxmox.com... 188.165.145.222
Connecting to download.proxmox.com|188.165.145.222|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 27816 (27K) [application/x-debian-package]
Saving to: `dab_1.1-14_all.deb'
100%[======================================>] 27,816 40.2K/s in 0.7s
2011-05-20 19:15:58 (40.2 KB/s) - `dab_1.1-14_all.deb' saved [27816/27816]
(Reading database ... 26449 files and directories currently installed.)
Preparing to replace dab 1.1-12 (using dab_1.1-14_all.deb) ...
Unpacking replacement dab ...
Setting up dab (1.1-14) ...
Processing triggers for man-db ...
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name Version Description
+++-==============-==============-============================================
ii dab 1.1-14 Debian OpenVZ Appliance Builder
install: libjpeg62
install: php5-gd
install: php5
sed -e 's/^\s*display_errors\s*=\s*On/display_errors = Off/' -i /var/lib/vz/private/90000/etc/php5/apache2/php.ini
dab install php5-mysql
install: php5-mysql
tar xzf latest.tar.gz -C /var/lib/vz/private/90000/var/www/
# change owner, in order to enable web based updates
dab exec chown -R www-data.www-data /var/www/wordpress
install -m 0644 wordpress.conf /var/lib/vz/private/90000/etc/apache2/sites-available/wordpress
install -m 0755 wordpress_setup /var/lib/vz/private/90000/etc/init.d/
dab exec insserv wordpress_setup
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
dab exec a2enmod rewrite
Enabling module rewrite.
Run '/etc/init.d/apache2 restart' to activate new configuration!
dab exec a2dissite default
Site default disabled.
Run '/etc/init.d/apache2 reload' to activate new configuration!
dab exec a2ensite wordpress
Enabling site wordpress.
Run '/etc/init.d/apache2 reload' to activate new configuration!
dab finalize
cleanup package status
update available package list
detecting final size: 490 MB
creating final appliance archive
INIT LOGOnline
starting init logger
INIT: version 2.88 booting
stty: standard input: Invalid argument
Using makefile-style concurrent boot in runlevel S.
Activating swap...done.
mount: permission denied
Cleaning up ifupdown....
Setting up networking....
Fast boot enabled, so skipping file system check. ... (warning).
Mounting local filesystems...done.
Activating swapfile swap...done.
Cleaning up temporary files....
Configuring network interfaces...done.
Starting portmap daemon....
Cleaning up temporary files....
Setting kernel variables ...done.
INIT: Entering runlevel: 2
stty: standard input: Invalid argument
Using makefile-style concurrent boot in runlevel 2.
Starting portmap daemon...Already running..
Starting enhanced syslogd: rsyslogd.
Starting deferred execution scheduler: atd.
Starting periodic command scheduler: cron.
Starting MySQL database server: mysqld.
Checking for corrupt, not cleanly closed and upgrade needing tables..
Generate random MySQL root password
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
Starting Postfix Mail Transport Agent: postfix.
generating ssh host keys
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
Starting OpenBSD Secure Shell server: sshd.
Generate Wordpress Siteconfig
insserv: warning: script is corrupt or invalid: /etc/init.d/../rc6.d/S00vzreboot
Starting web server: apache2.
INIT: no more processes left in this runlevel
install: libjpeg62
install: php5-gd
install: php5
sed -e 's/^\s*display_errors\s*=\s*On/display_errors = Off/' -i /var/lib/vz/private/90000/etc/php5/apache2/php.ini
dab install php5-mysql
install: php5-mysql
tar xzf latest.tar.gz -C /var/lib/vz/private/90000/var/www/
# change owner, in order to enable web based updates
dab exec chown -R www-data.www-data /var/www/wordpress
install -m 0644 wordpress.conf /var/lib/vz/private/90000/etc/apache2/sites-available/wordpress
install -m 0755 wordpress_setup /var/lib/vz/private/90000/etc/init.d/
dab exec insserv wordpress_setup
dab exec a2enmod rewrite
Enabling module rewrite.
Run '/etc/init.d/apache2 restart' to activate new configuration!
dab exec a2dissite default
Site default disabled.
Run '/etc/init.d/apache2 reload' to activate new configuration!
dab exec a2ensite wordpress
Enabling site wordpress.
Run '/etc/init.d/apache2 reload' to activate new configuration!
dab finalize
cleanup package status
update available package list
detecting final size: 490 MB
creating final appliance archive
README S14rsyslog S15ssh S18apache2
S01bootlogs S15atd S16mysql_randompw S19rc.local
S01ssh_gen_host_keys S15cron S16postfix S19rmnologin
S12portmap S15mysql S17wordpress_setup S19stop-bootlogd
pve-manager: 1.8-17 (pve-manager/1.8/5948)
running kernel: 2.6.32-4-pve
proxmox-ve-2.6.32: 1.8-33
pve-kernel-2.6.32-4-pve: 2.6.32-33
qemu-server: 1.1-30
pve-firmware: 1.0-11
libpve-storage-perl: 1.0-17
vncterm: 0.9-2
vzctl: 3.0.26-1pve4
vzdump: 1.2-12
vzprocps: 2.0.11-2
vzquota: 3.0.11-1
pve-qemu-kvm: 0.14.0-3
ksm-control-daemon: 1.0-5
What program creates the said file on first boot?
We use essential cookies to make this site work, and optional cookies to enhance your experience.