WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: persistent installation [SOLVED]  (Read 3768 times)

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
persistent installation [SOLVED]
« on: July 12, 2009, 05:03:11 PM »
Hi!

I just tried out TinyCore. For my server i need ruby with rails installed. installing it within the booted system was no problem but i want to backup the system (because the sqlite databases changes frequently) to have no dataloses on reboot. could someone help with that?

greetings
nurbs999
« Last Edit: July 16, 2009, 05:35:20 AM by nurbs999 »

Offline Guy

  • Hero Member
  • *****
  • Posts: 1089
Re: persistent installation
« Reply #1 on: July 13, 2009, 07:25:43 AM »
Add the names of any folders you want saved to /opt/.filetool.lst so they are included in backup.

/backup.html][removed due to policy violation]/backup.html
« Last Edit: August 30, 2009, 09:20:45 AM by Guy »
Many people see what is. Some people see what can be, and make a difference.

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
Re: persistent installation
« Reply #2 on: July 13, 2009, 08:59:35 AM »
and everything will be restored after reboot or do i have to restore everything manually?

and how can i run backup frpm console so that i create a backup frequently via cron.

Offline Guy

  • Hero Member
  • *****
  • Posts: 1089
Re: persistent installation
« Reply #3 on: July 13, 2009, 09:56:10 AM »
Quote
and everything will be restored after reboot or do i have to restore everything manually?

When you first run Tiny Core, you need to select the backup location.

To do this, open the control panel and select Backup/Restore. It is ideal to put it in the tce folder. For example sda1/tce.

Each time you shut down Tiny Core, it will be backed up unless you untick the backup box.

Each time you start Tiny Core, it will restore the last backup. You can use a boot code so it doesn't.
Many people see what is. Some people see what can be, and make a difference.

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
Re: persistent installation
« Reply #4 on: July 14, 2009, 02:15:35 AM »
ok, ill give this a try, but i still don't know, how to backup the sqlite databases (except with a dump and a startup script to restore the dump)


edit:  since sqlite stores its databases in a simple file the backup should restore the database. thx for your answers.

one last thing: how do i create a backup via console, so that i can run it through  a cron job to prevent data loses if the system should crash.
« Last Edit: July 14, 2009, 05:16:25 AM by nurbs999 »

Offline Kingdomcome

  • Sr. Member
  • ****
  • Posts: 286
Re: persistent installation
« Reply #5 on: July 14, 2009, 09:44:18 AM »
Code: [Select]
/usr/bin/filetool.sh backup nowand you are correct, sqlite dbs are a single file that can be backed up, restored, moved around, etc

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
Re: persistent installation
« Reply #6 on: July 15, 2009, 06:22:25 PM »
ok, backup works now, but it doesn't save installed programs.
i don't think i have to include EVERYTHING in the backup, meaning the whole filesystem.

btw, i installed everything from the tce tree.

Offline linus72

  • Full Member
  • ***
  • Posts: 196
  • Damn it Jim!
Re: persistent installation
« Reply #7 on: July 15, 2009, 06:51:04 PM »
OK
you gotta tell tc where to put the tce folder to save apps

restore=sdxx tce=sdxx
where sdxx is usb; sda1, sdb1, etc

or for hd just replace with hda1, etc

so, at boot enter codes above
then boot and tc will make a folder named tce there
and start adding apps
if you install ALL tce's you better have alot of RAM:)

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
Re: persistent installation
« Reply #8 on: July 16, 2009, 04:50:44 AM »
thx for the tip linux, but i have another problem now ;)

filetool.sh is called to soon. i have stored everything on a pendrive which is recognized by the kernel AFTER filetool is called. so get a "invalid device" error.

a workaround could be to code a "sleep 5" into the filetool script, but i guess thats not the way to do it??

Offline linus72

  • Full Member
  • ***
  • Posts: 196
  • Damn it Jim!
Re: persistent installation
« Reply #9 on: July 16, 2009, 05:22:29 AM »
OH, maybe you mean the cheatcode "waitusb=5"
not sleep, but waitusb=5 or waitusb=10
5 sec works for mine
also, make sure tinycore recognizes your usb name
it might be sda1, sdb1, sdc1, sdd1, sde1, sdf1,
and to find out
boot withthe code "base norestore nolocal superuser"
this will boot you to a console as root
at commandline enter "fdisk -l"
that's a little L

that will tell you usb name
now try mounting it to be sure
so if it's /dev/sdb1
type in
"mount /mnt/sdb1"
if it says that mount point doesn't exist yet
"mkdir /mnt/sdb1"
then "mount /dev/sdb1 /mnt/sdb1"

then do
"ls /mnt/sdb1"
thats a small L and a small S
this will show contents of usb

now that you know the usb name, reboot
"reboot"
then at boot edit boot: line with
restore=sdb1 tce=sdb1 waitusb=5 max_loop=255 xsetup

that should help :-X

Offline nurbs999

  • Newbie
  • *
  • Posts: 8
Re: persistent installation
« Reply #10 on: July 16, 2009, 05:34:48 AM »
great, thank you VERY much, now i'm happy ;)

i just need to get rails running, but that's another topic.

Offline linus72

  • Full Member
  • ***
  • Posts: 196
  • Damn it Jim!
Re: persistent installation [SOLVED]
« Reply #11 on: July 16, 2009, 06:15:47 AM »
You still must edit menu.lst or syslinux/extlinux.cfg to make it permanet
did you already do that?
you don't have to do the xsetup on .cfg/menu.lst files
you can also do the bootcodes
home=sdxx opt=sdxx
and lots more cheatcodes too
( http://tinycorelinux.com/faq.html#bootcodes )

I set mine up with "noicons" too
dragon themes are jwm tinycore
( http://multidistro.com/tinycore-shots/tc-scrnshots.html )

if want themes in opt/jwmThemes folder
add
opt/jwmThemes
to filetool.lst

I am gonna be submitting themes today so master Roberts can make a tce for them:)