-
Re: stupid stupid stupid knoppix

Originally Posted by
MrAhmad
every time I custom the KDE,Mozilla Bookmark , Openoffice, and other and then I copy them to
/etc/skel/ (and even to /usr/share/knoppix/profile) but It still create a new home for knoppix with the default settings (not with /etc/skel)
I searched the forum but I can't find any good solution
Any help pleaaaaseee

First things first:
1) when you boot, are the files in /etc/skel at least?
Anyhow, I've had a similar problem and resolved the following way (supposing, you're already CHROOTed!):
1) copy all the files you wish to be in /home/USER to /opt/
2) Create a scripts directory inside /opt
Code:
mkdir /opt/startup_scripts
3) create the init script to copy the files
Code:
touch /etc/init.d/copy_home_files
4) copy_home_files content
Code:
#!/bin/sh
case "$1" in
start)
echo -n "Starting COPY FILES TO HOME DIRECTORY"
start-stop-daemon --start --quiet --exec /opt/startup_scripts/startup.sh \
-- $PARAMS
echo "."
;;
*)
echo "Usage: /etc/init.d/copy_home_files " \
" {start}" >&2
exit 1
;;
esac
exit 0
5) Now lets make the actual script
Code:
touch /opt/startup_scripts/startup.sh
6) startup.sh content
Code:
#!/bin/sh
cp -R /opt/xml /home/knoppix
chown -R knoppix:knoppix /home/knoppix/xml
cp -R /opt/.mozilla /home/knoppix
chown -R knoppix:knoppix /home/knoppix/.mozilla
cp -R /opt/jakarta-tomcat-4.1.27 /home/knoppix
chown -R knoppix:knoppix /home/knoppix/jakarta-tomcat-4.1.27
mkdir /home/knoppix/.icewm
echo "#!/bin/bash
mozilla
" > /home/knoppix/.icewm/startup
chown knoppix:knoppix /home/knoppix/.icewm/startup
chmod 755 /home/knoppix/.icewm/startup
you get the picture... (this is my actual script!)
7) and finally, we add the startup script to the boot process by
Code:
update-rc copy_home_files defaults > /dev/null
THERE!!! Now when your system (on the cd) boots, your files should be copied from /opt/WHATEVER_FILES to /home/USER/...
Good luck!
enrolado
Similar Threads
-
By pf123 in forum General Support
Replies: 3
Last Post: 09-28-2004, 05:53 PM
-
By osaria in forum General Support
Replies: 3
Last Post: 09-09-2004, 05:54 PM
-
By spite in forum Customising & Remastering
Replies: 2
Last Post: 10-07-2003, 02:53 PM
-
By Ander in forum General Support
Replies: 2
Last Post: 06-26-2003, 10:54 PM
-
By Gandalf_Grey_ in forum Customising & Remastering
Replies: 2
Last Post: 01-23-2003, 02:44 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

Kingston 32GB 64GB 128GB 256GB USB 3.0 Flash Drive Thumb Memory Stick Pen lot
$285.90

SK Hynix 32GB 4Rx4 PC4-2133P-LD0-10 HMA84GL7MMR4N-TF TD DDR4 Server Memory RAM
$110.00

TF/SD Card Adapter Camera Reader Android Type-c For iPhone17 Pro Max Plusm lot
$573.98

Micron MTC40F2046S1RC48BA1 DDR5 64GB (1x64GB) 4800MHz RDIMM ECC Server Memory
$2599.99

LOT SK hynix 256GB 8x32GB DDR4-2666 ECC RDIMM HMA84GR7AFR4N-VK Lenovo 01AG619
$1200.00

USB 3.0 Flash Drive 32GB 64GB 128GB Memory Stick Thumb Stick Lot Pack
$826.09

Lot of 3 Micron MTA18ASF2G72PDZ-2G9E1UI 16GB 2Rx8 PC4-2933Y-RE2-12 Server RAM
$179.99

Lot Of 16 X 16GB ECC DIMM Server Memory SK Hynix HMA42GR7MFR4N-TF PC4-17000 DDR4
$800.00

LOT OF 30 8GB 2Rx4 PC3L-10600R-9-11-E2 MT36KSF1G72PZ-1G4M1FF DDR3 Server RAM
$274.99

Lot Of 50 8GB DDR4 RAM PC4-2666V-UA2 DIMM Desktop Memory Mixed Brands TESTED
$1750.00