Porteus Tips and Tricks
To view the discussion about this document, or to ask a question about it, visit this thread on our forum.
- Porteus is Live!
- Use a 'save.dat' container for FAT or NTFS drives
- Copy to RAM
- Use your rootcopy folder for quick changes or additions
- Use Magic Folders for more flexibility
- Porteus CD customization
- Compiling drivers from source
- Run Porteus from a USB drive, even if not supported by your BIOS
- CLI Utilities
- Use quickstart menu
- Manage your packages and modules from the GUI
- Use 'Always Fresh' mode, and be free to experiment!
Porteus is a live distribution, which means that the running environment is constructed in your system's memory when you boot it up. The porteus files on your CD, flash drive, or hard drive are mounted and used to construct this live filesystem. For more information, go here.
If you want to save all the changes that you make to your system (configuration, downloaded files, bookmarks, etc.,) to a drive that is formatted with a window's filesystem, you need to use a save.dat container file. This is because Windows filesystems are not built to handle linux files. For more information, visit this link.
You can modify and customize the way your system boots, and resolve or work around many hardware issues by using cheatcodes. Cheatcodes are passed to the system by pressing TAB at the boot menu (when the porteus graphic comes up with the options to boot into KDE, XFCE, LXQT or MATE) and entering a short string of text. See this link for more info (this file can also be found on your system at /boot/docs/cheatcodes.txt)
Porteus has a boot option (implemented by a cheatcode) called copy2ram. Selecting this boot option means that all of the files inside your modules will be copied into your system's RAM. This slows down your boot process and uses up more of your RAM, but it also produces an incredibly fast, responsive system because all of the files are already loaded and available for use.
You can save individual files to your "rootcopy" folder, after which they will be added to your live filesystem at startup. This is useful for saving your configuration files (among other things) when you are booting into "Always Fresh" mode, without the need to compress these files into a module. For more information, go here.
You can use the Magic Folders tool from 'Porteus Settings Centre' to set up paired folders, which will mirror a directory from your storage media on your live filesystem, and changes made to that directory from within Porteus will be saved back to your storage media. This allows you to save changes to specific locations, rather than saving all of your changes for the whole system. Go here for more information.
Though CD's and DVD's are technically "read only" media, there are a number of ways that you can customize Porteus while running from a CD or DVD. One can utilize cheatcodes (see the link above, or the cheatcodes.txt file inside the boot/docs/ folder on your CD), such as 'noload=kde' to make the system boot into XFCE faster, or 'extramod=/path/to/mod' to load modules from a hard drive, usb drive, etc. You can also extract the .iso file for the CD, make modifications, add modules, etc., and remaster a new .iso (using make_iso.bat or make_iso.sh inside the /porteus folder), and burn that to a CD, for your own customized version.
If you have hardware that is not supported by Porteus out of the box, you may need to compile a driver from source. Some of these drivers need access to the kernel configuration files, which are not included in porteus by default (this is to reduce the size of the porteus .iso). In order to compile these drivers, you will first need to download the "development" module from the porteus server and activate it. This will insert a stripped-down version of the kernel source in the /usr/src/ folder. Now you're ready to compile the driver per the "readme" instructions included with the source code. It is best to compile using the DESTDIR variable, so that you can install the driver and it's files to a fake root folder, which can then be easily turned into a module using the dir2xzm function. If there is no DESTDIR variable in the Makefile, you can also build the drivers and install them to your system, and then use the built-in "changes-time" script, which will pull out all of the files you have added or modified in your system over a specified period of time (e.g. the last three minutes).
If your computer has a USB port but your BIOS does not support booting directly from USB, you can still run Porteus from your USB drive. To do this, you can split your Porteus installation as follows:
- /boot folder on CD
- /porteus folder on usb stick
Now you can boot from the CD and linuxrc script will find the /porteus folder on the USB drive. All cheatcodes like 'from=', 'changes=' still apply here, just like a normal USB installation.
To enable a firewall in Porteus open 'Porteus Settings Centre' and click on the 'Security settings' box. Here you can find a firewall with some pre-definied settings.
Porteus has some aliases set in ~/.bashrc (home directory). It's good to know that they exist so you can use them in the console.
Porteus has some nice CLI utilities which may be forgotten or never found by most users. Here is the list with short descriptions:
changes-time - copies all files that have been added or modified on your system over a specified period of time.
fromdos/todos - CLI utilities which convert documents between windows/unix formatting
mloop - a great tool by brokenman for mounting modules/iso/dat files on a loop device. e.g. mloop mycustom.iso
pxe-boot - run this short script to start PXE boot services. This is useful when you did not choose 'PXE boot option' at the start and dont want to reboot.
save-changes - dump whole changes from the live session into a module
update-module - searches your system for changes that have been made to the files from a specified module, and updates the module with those changes.
While logged into the desktop, use the 'Alt+F2' key combination to quickstart applications
File managers (caja/thunar/dolphin/pcmanfm-qt) have extra service menus specific to Porteus only. All you need to do is right click on a certain file type to get an option for an extra action:
- folders: you can build a Porteus module from it
- modules: you can extract it to a folder; mount it to a folder (same function as 'mloop' utility)
- tgz/txz slackware packages: you can convert it to xzm; install/uninstall directly to/from live system
- rpm packages: convert to xzm
- deb packages: convert to xzm
When you boot in Always Fresh mode (meaning, without the changes= cheatcode or magic folders), none of the changes you make to your live filesystem will survive reboot. So, you can tear apart your system, leave a mess behind you, and it will all get flushed the next time you boot up. This makes you free to experiment with the system, to change things up, without fear that you will 'break' your system and have to reinstall. You can still customize your experience, by using your rootcopy folder, creating modules out of your custom configuration files, etc. Just be careful -- if you spend a lot of time working on something and leave it on your desktop without saving it to your storage media, it will be gone forever.