site  contact  subhomenews

Bring back first boot

September 21, 2015 — BarryK
This will be of interest to all Puppy developers and many testers.

I have built a new Quirky, installed it to USB stick, but managed to get X all messed up. I want to go back to the "very first bootup" situation, but how?

Actually, it is not simple to do, many files are involved. The thing to do is bootup some other pup, then mount the partition where the troublesome pup is installed. In my case it is /dev/sdb2, so I will use that. Then, follow these instructions:

Any Quirky, Puppy, or derivative installation, to restore to pristine "first startup" condition, delete these, if they exist:

/mnt/sdb2/etc/X11/xorg.conf, xorg.conf.*
/mnt/sdb2/root/.network-firmware*, .usb-drive-log*
/mnt/sdb2/root/.pup_event/* careful that you only delete xorg.conf and xorg.conf.* (where * is a glob wildcard, this is not a regular expression). Do not delete xorg.conf0 or xorg.conf-auto-pc.

Quirky has /var mounted as a tmpfs, and contents disappear at shutdown, except for /var/local which is actually at /root/.var/local. Delete these:

/mnt/sdb2/root/.var/local/delayedrun_firstboot_flag, shutdown_date_saved, quickset*, etc_profile_at_shutdown

For pups that have a normal /var not mounted as a tmpfs, delete:
/mnt/sdb2/var/local/delayedrun_firstboot_flag, shutdown_date_saved, quickset*, etc_profile_at_shutdown

Quirky, and the most recent puppies that I developed, have /tmp mounted as a tmpfs, so contents of /tmp will disappear after reboot. However, if you have a pup that has a /tmp that persists over a reboot, then delete this:


Most pups boot with automatic startup of X, however, the xorgwizard may change this parameter. Edit the file /mnt/sdb2/etc/DISTRO_SPECS and make sure set to 'yes':


There are more files that get created at first bootup, but unlikely to have any importance. However, you might like to delete these to get closer to perfect pristine first-time bootup:


I did all of the above, and my USB stick booted up as if for the very first time.
Actually, this would be a useful boot parameter, such as "qfix=first". Might do that.

Tags: linux