In the livecd scripts store logs in /var/log instead of /tmp

This commit is contained in:
Ramon Buldó 2015-05-27 06:28:57 +02:00
parent 7afcf4524c
commit 7184df638f
3 changed files with 16 additions and 16 deletions

View file

@ -273,7 +273,7 @@ configure_translation_pkgs(){
install_localization(){ install_localization(){
if [ -e "/bootmnt/${iso_name}/${arch}/lng-image.sqfs" ] ; then if [ -e "/bootmnt/${iso_name}/${arch}/lng-image.sqfs" ] ; then
echo "install translation packages" >> /tmp/livecd.log echo "install translation packages" >> /var/log/livecd.log
configure_translation_pkgs $1 configure_translation_pkgs $1
${PACMAN_LNG} -Sy ${PACMAN_LNG} -Sy
if [ -e "/bootmnt/${iso_name}/${arch}/kde-image.sqfs" ] ; then if [ -e "/bootmnt/${iso_name}/${arch}/kde-image.sqfs" ] ; then
@ -295,7 +295,7 @@ install_localization(){
} }
configure_alsa(){ configure_alsa(){
echo "configure alsa" >> /tmp/livecd.log echo "configure alsa" >> /var/log/livecd.log
# amixer binary # amixer binary
local alsa_amixer="chroot $1 /usr/bin/amixer" local alsa_amixer="chroot $1 /usr/bin/amixer"
@ -372,7 +372,7 @@ rm_kalu(){
configure_machine_id(){ configure_machine_id(){
# set unique machine-id # set unique machine-id
echo "Setting machine-id ..." >> /tmp/livecd.log echo "Setting machine-id ..." >> /var/log/livecd.log
dbus-uuidgen --ensure=/etc/machine-id dbus-uuidgen --ensure=/etc/machine-id
ln -sf /etc/machine-id /var/lib/dbus/machine-id ln -sf /etc/machine-id /var/lib/dbus/machine-id
} }

View file

@ -11,7 +11,7 @@ CONSOLEMAP="$(kernel_cmdline vconsole.font.map)"
PACMAN_LNG="pacman --config /opt/livecd/pacman-lng.conf --noconfirm --noprogressbar" PACMAN_LNG="pacman --config /opt/livecd/pacman-lng.conf --noconfirm --noprogressbar"
arch=$(uname -m) arch=$(uname -m)
echo "update fstab for swap" > /tmp/livecd.log echo "update fstab for swap" > /var/log/livecd.log
# scan_swap # scan_swap
## Systemd should do it ## Systemd should do it
@ -19,25 +19,25 @@ echo "update fstab for swap" > /tmp/livecd.log
# [[ -d /run/openrc ]] && configure_swap # [[ -d /run/openrc ]] && configure_swap
configure_swap configure_swap
echo "set locale" >> /tmp/livecd.log echo "set locale" >> /var/log/livecd.log
# set language # set language
configure_language configure_language
locale-gen locale-gen
echo "configure system" >> /tmp/livecd.log echo "configure system" >> /var/log/livecd.log
# add BROWSER var # add BROWSER var
configure_env configure_env
configure_machine_id configure_machine_id
echo "configure sudoers" >> /tmp/livecd.log echo "configure sudoers" >> /var/log/livecd.log
# do_fix_perms # do_fix_perms
configure_sudo configure_sudo
echo "depmod extramodules" >> /tmp/livecd.log echo "depmod extramodules" >> /var/log/livecd.log
# depmod extramodules # depmod extramodules
depmod $(cat /usr/lib/modules/$(uname -r)/extramodules/version) depmod $(cat /usr/lib/modules/$(uname -r)/extramodules/version)
@ -46,7 +46,7 @@ install_localization
configure_displaymanager configure_displaymanager
echo "configure root password" >> /tmp/livecd.log echo "configure root password" >> /var/log/livecd.log
configure_user_root / configure_user_root /
cp -a /etc/skel/. /root/ cp -a /etc/skel/. /root/

View file

@ -9,7 +9,7 @@ VIDEO="$(kernel_cmdline xdriver no)"
seconds="0" seconds="0"
while [ -e "/var/lib/pacman/db.lck" ]; while [ -e "/var/lib/pacman/db.lck" ];
do do
echo 'Pacman is not ready yet. Will try again in 5 seconds.' >> /tmp/livecd.log echo 'Pacman is not ready yet. Will try again in 5 seconds.' >> /var/log/livecd.log
seconds=$(($seconds + 5)) seconds=$(($seconds + 5))
sleep 5 sleep 5
if [[ "$seconds" == "15" ]]; then if [[ "$seconds" == "15" ]]; then
@ -21,20 +21,20 @@ done
# hwdetect_graphics # hwdetect_graphics
if [[ -e "/opt/livecd/pacman-gfx.conf" ]]; then if [[ -e "/opt/livecd/pacman-gfx.conf" ]]; then
echo "run mhwd" >> /tmp/livecd.log echo "run mhwd" >> /var/log/livecd.log
if [[ "${USENONFREE}" == "yes" ]] || [[ "${USENONFREE}" == "true" ]]; then if [[ "${USENONFREE}" == "yes" ]] || [[ "${USENONFREE}" == "true" ]]; then
if [[ "${VIDEO}" == "vesa" ]]; then if [[ "${VIDEO}" == "vesa" ]]; then
mhwd --install pci video-vesa --pmconfig "/opt/livecd/pacman-gfx.conf" >> /tmp/livecd.log mhwd --install pci video-vesa --pmconfig "/opt/livecd/pacman-gfx.conf" >> /var/log/livecd.log
else else
mhwd --auto pci nonfree 0300 --pmconfig "/opt/livecd/pacman-gfx.conf" >> /tmp/livecd.log mhwd --auto pci nonfree 0300 --pmconfig "/opt/livecd/pacman-gfx.conf" >> /var/log/livecd.log
fi fi
else else
if [[ "${VIDEO}" == "vesa" ]]; then if [[ "${VIDEO}" == "vesa" ]]; then
mhwd --install pci video-vesa --pmconfig "/opt/livecd/pacman-gfx.conf" >> /tmp/livecd.log mhwd --install pci video-vesa --pmconfig "/opt/livecd/pacman-gfx.conf" >> /var/log/livecd.log
else else
mhwd --auto pci free 0300 --pmconfig "/opt/livecd/pacman-gfx.conf" >> /tmp/livecd.log mhwd --auto pci free 0300 --pmconfig "/opt/livecd/pacman-gfx.conf" >> /var/log/livecd.log
fi fi
fi fi
fi fi
echo "MHWD DONE" >> /tmp/livecd.log echo "MHWD DONE" >> /var/log/livecd.log