Heyas
So i have my custom Fedora with AwesomeWM spin with alots of customizations using the kickstart method for a liveimage.
A few weeks (2-3 months) ago, i've done some changes i cannot remember.
Those changes made the image from bootable to gui, to not booting to gui any more.
Just figured that out about 2 weeks ago, and after i spent 8 hours today (about 14-16 builds), i could pintpoint the bad to a script that is executed within %post section.
However, to me its a deadend, as i really dont understand how that could be the cause, however, when that script is started, the image wont boot to gui, and if its not executed, i'm missing all my customizations.
My system is Fedora 20 : 3.16.2-201.fc20.x86_64
This one is just to be complete:
%post
#!/bin/bash
cd /root/spin_files/scripts
sh skel-config.sh # Problem is within here !!
# sh skel-awesome.sh
sh post-livesys.sh
#
# This goes at the end after all other changes.
#
echo
echo "selinux restorecon"
echo
useradd -m liveuser
/usr/sbin/chown -R liveuser:liveuser /home/liveuser
/usr/sbinrestorecon -R /home/liveuser
%end
This one is what i've pinpointed after 8 hrs of trial and error builds: post-skel.sh
#!/bin/bash
echo
echo "Somewhere BELOW is error"
echo
#
# Copy fixed template
#
cd /root/spin_files/skel
# rm -f /etc/skel/.bashrc
cp -fr * /etc/skel
cp -fr .[a-zA-Z]* /etc/skel
ln -sf /root/spin_files/make-iso.sh /usr/bin/make-awesomewm
# The 'cd' is required for the other scripts to work
cd ..
echo
echo "Somewhere ABOVE is error"
echo
This is how it looks (note i've removed the pwd & ls commands above for better readability):
Writing LXDE & LXDM conf
DONE LXDM conf
post-myscript.sh
DONE post-myscript.sh
Prepare files in /root/spin_files
* 001-system-settings.ks
* 005-repo-sea.ks
* 006-repo-non-foss-rawhide.ks
* 006-repo-non-foss.ks
* 008-pkgs-awesome.ks
* 009-pkgs-dev.ks
* 010-pkgs-nonfoss.ks
* 011-pkgs-rescue.ks
* 020-post-nochroot.ks
* 021-post-chroot.ks
* 022-post-skel.ks
* 999-post-fedora-template.ks
DONE 021-post-chroot.ks
Somewhere BELOW is error
--------------
/root/spin_files/skel
total 32
-rw-r--r--. 1 root root 2118 Sep 22 14:11 README
-rw-r--r--. 1 root root 506 Sep 22 14:11 cheatsheet-awesomewm-hotkeys.txt
drwxr-xr-x. 2 root root 4096 Sep 22 14:11 data
drwxr-xr-x. 5 root root 4096 Sep 22 14:11 mm
drwxr-xr-x. 6 root root 4096 Sep 22 14:11 net
drwxr-xr-x. 2 root root 4096 Sep 22 14:11 notepad
drwxr-xr-x. 5 root root 4096 Sep 22 14:11 priv
drwxr-xr-x. 2 root root 4096 Sep 22 14:11 prjs
--------------
--------------
/etc/skel
total 32
-rw-r--r--. 1 root root 2118 Sep 22 14:12 README
-rw-r--r--. 1 root root 506 Sep 22 14:12 cheatsheet-awesomewm-hotkeys.txt
drwxr-xr-x. 2 root root 4096 Sep 22 14:12 data
drwxr-xr-x. 5 root root 4096 Sep 22 14:12 mm
drwxr-xr-x. 6 root root 4096 Sep 22 14:12 net
drwxr-xr-x. 2 root root 4096 Sep 22 14:12 notepad
drwxr-xr-x. 5 root root 4096 Sep 22 14:12 priv
drwxr-xr-x. 2 root root 4096 Sep 22 14:12 prjs
--------------
Somewhere ABOVE is error
(Over-)Writing livesys // post-livesys.sh
DONE post-livesys.sh
selinux restorecon
/tmp/ks-script-xfa88y: line 12: useradd: command not found
/tmp/ks-script-xfa88y: line 13: /usr/sbin/chown: No such file or directory
/tmp/ks-script-xfa88y: line 14: /usr/sbinrestorecon: No such file or directory
ignoring %post failure (code 127)
The unit files have no [Install] section. They are not meant to be enabled
using systemctl.
I've checked the file permissions with my host system, and they look the same..
:) /etc/skel # ls -la
insgesamt 40
drwxr-xr-x. 3 root root 4096 12. Sep 18:39 .
drwxr-xr-x. 132 root root 12288 22. Sep 12:05 ..
-rw-r--r--. 1 root root 18 21. Jul 13:52 .bash_logout
-rw-r--r--. 1 root root 193 21. Jul 13:52 .bash_profile
-rw-r--r--. 1 root root 231 21. Jul 13:52 .bashrc
-rw-r--r--. 1 root root 172 24. Jul 13:50 .kshrc
drwxr-xr-x. 4 root root 4096 26. Jul 22:16 .mozilla
-rw-r--r--. 1 root root 658 28. Aug 22:57 .zshrc
I am aware of the 3 command errors, but they dont seem to have any effect on the no-gui-issue, because either with them - but unused post-skel.sh - i CAN (just did last build) boot to GUI within the VM.
Name : VirtualBox
Architektur : x86_64
Version : 4.3.16
Ausgabe : 1.fc20
Please understand, that for useradd, chown and restorecon, i've just added their folders like 4 builds ago as they were not found without, nor are with it (fixing the typo now).
Any ideas why the change of the /etc/skel results in an image that doesnt boot to GUI?
Thank you in advance
Simon
EDIT:
To be complete, this is the project strucutre on the host system:
+ /home/sea/prjs/iso-awesome-sea # ll -a *
-rw-rw-r--. 1 sea sea 1285 22. Sep 10:32 AwesomeWM.ks
-rw-rw-r--. 1 sea sea 1188 28. Aug 21:36 AwesomeWM-rawhide.ks
-rw-rw-r--. 1 sea sea 35147 31. Aug 14:53 gpl.txt
-rw-rw-r--. 1 sea sea 269 14. Sep 00:18 make-iso.conf
-rwxrwxr-x. 1 sea sea 2254 14. Sep 00:31 make-iso.sh
-rw-rw-r--. 1 sea sea 1658 31. Aug 20:07 README.md
-rw-rw-r--. 1 sea sea 81932 11. Mai 17:19 screenshot-clean.jpg
ks:
insgesamt 60
drwxrwxr-x. 2 sea sea 4096 22. Sep 13:51 .
drwxrwxr-x. 6 sea sea 4096 22. Sep 14:20 ..
-rw-rw-r--. 1 sea sea 431 31. Aug 15:03 001-system-settings.ks
-rw-r--r--. 1 sea sea 194 22. Sep 02:46 005-repo-sea.ks
-rw-rw-r--. 1 sea sea 1724 17. Sep 13:47 006-repo-non-foss.ks
-rw-rw-r--. 1 sea sea 1725 29. Aug 00:45 006-repo-non-foss-rawhide.ks
-rw-rw-r--. 1 sea sea 1163 17. Sep 16:36 008-pkgs-awesome.ks
-rw-rw-r--. 1 sea sea 246 2. Sep 23:27 009-pkgs-dev.ks
-rw-rw-r--. 1 sea sea 424 17. Sep 17:46 010-pkgs-nonfoss.ks
-rw-rw-r--. 1 sea sea 45 3. Sep 00:37 011-pkgs-rescue.ks
-rw-rw-r--. 1 sea sea 1396 1. Sep 02:33 020-post-nochroot.ks
-rw-rw-r--. 1 sea sea 167 22. Sep 06:28 021-post-chroot.ks
-rw-rw-r--. 1 sea sea 346 22. Sep 13:51 022-post-skel.ks
-rw-rw-r--. 1 sea sea 7650 2. Sep 23:27 999-post-fedora-template.ks
scripts:
insgesamt 44
drwxrwxr-x. 3 sea sea 4096 22. Sep 13:53 .
drwxrwxr-x. 6 sea sea 4096 22. Sep 14:20 ..
drwxrwxr-x. 2 sea sea 4096 1. Sep 19:25 bin
-rw-rw-r--. 1 sea sea 114 30. Aug 10:25 __DONT__execute_README
-rw-rw-r--. 1 sea sea 660 30. Aug 16:39 post-grub.sh
-rw-rw-r--. 1 sea sea 1529 22. Sep 08:24 post-livesys.sh
-rw-rw-r--. 1 sea sea 1034 22. Sep 06:27 post-lxdm.sh
-rw-rw-r--. 1 sea sea 260 22. Sep 06:26 post-myscripts.sh
-rw-rw-r--. 1 sea sea 409 22. Sep 06:26 post-sustain.sh
-rw-rw-r--. 1 sea sea 229 30. Aug 10:35 skel-awesome.sh
-rw-rw-r--. 1 sea sea 505 22. Sep 13:53 skel-config.sh
skel:
insgesamt 64
drwxrwxr-x. 10 sea sea 4096 22. Sep 13:25 .
drwxrwxr-x. 6 sea sea 4096 22. Sep 14:20 ..
-rw-r--r--. 1 sea sea 18 2. Sep 2013 .bash_logout
-rw-r--r--. 1 sea sea 193 2. Sep 2013 .bash_profile
-rw-rw-r--. 1 sea sea 1322 22. Sep 13:25 .bashrc
-rw-rw-r--. 1 sea sea 506 28. Aug 23:50 cheatsheet-awesomewm-hotkeys.txt
drwxrwxr-x. 10 sea sea 4096 31. Aug 12:41 .config
drwxrwxr-x. 2 sea sea 4096 29. Aug 18:40 data
-rw-rw-r--. 1 sea sea 165 29. Aug 06:12 .gtk-bookmarks
drwxrwxr-x. 3 sea sea 4096 29. Aug 06:23 .local
drwxrwxr-x. 5 sea sea 4096 23. Apr 16:19 mm
drwxrwxr-x. 6 sea sea 4096 23. Apr 16:19 net
drwxrwxr-x. 2 sea sea 4096 23. Apr 16:19 notepad
drwxrwxr-x. 5 sea sea 4096 11. Mai 22:34 priv
drwxrwxr-x. 2 sea sea 4096 23. Apr 16:19 prjs
-rw-rw-r--. 1 sea sea 2118 31. Aug 14:51 README