18

November
2017

Some examples for Persistent Changes

In a reply to several questions about persistence, I'd like to put here few hints. Remember that this all works after reboot only if you select "Keep changes persistent" in the boot menu, and only if you are running Slax from a writable media such as USB disk.

1) how to make sshd server start automatically?

You can start ssh server manually by running service ssh start. If you run it the first time, it creates some keys in /etc/ssh/ directory, so the first start is a little bit longer. But even after the keys are created, sshd won't autostart on reboot. It's because I manually disabled it in Slax, because root's password is well known. So, make sure to change your root's password (and password of the guest user) to something new. When done, run systemctl enable ssh. It will basically create a symlink to ssh.service in multi-user.target.wants (which is in /etc/systemd/system directory). This ensures sshd will be started on boot.

2) How to make keyboard layout persistent?

I forgot to implement such functionality. So keyboard layout needs to be set from the fluxbox menu each time and there is no config file to change. You can make it persistent by editing /root/.fluxbox/startup ... add there a line such as setxkbmap fr for french keyboard layout, etc. Make sure it is somewhere on top of the file. I will probably fix the persistence of keyboard layout in next Slax release, so if you set it this way, you may need to remove it from the startup file again at some point later, when Slax fixes this.

3) how to disable autostart of Xorg?

Similarly like enabling ssh server, you may disable autostarting of X by the following command: systemctl disable xorg. This will remove display-manager.service symlink from /etc/systemd/system and you will get only text-mode console on next boot. You can still start X manually with the startx command after login, though.

User comments
ZAlex 2017-11-18 10:37

As for me, "Persistent Changes" aren't working even if I booted Slax with "Keep changes persistent" in the boot menu (it says "persistent changes not writable" during boot). But I made "slax/changes" folder manually (with one test file inside) and now this feature is working well... What about putting (empty?) "changes" folder inside the ISO image?

Tomas M 2017-11-18 11:49

There is indeed an empty directory '/slax/changes' in the ISO filesystem.
What tool you used to copy slax folder to your USB drive? That tool is probably broken :)

Tomas M 2017-11-18 11:50

Furthermore, even if the directory is not present, LiveKit creates it, as you can see at this line:
https://github.com/Tomas-M/linux-live/blob/master/livekitlib#L571

So I am wondering, what might cause the issue... strange

Jan T 2017-11-18 12:09

`service ssh start` should be equivalent to `systemctl start ssh`.

Also, maybe localectl can be used for permanently setting the keyboard layout: https://wiki.archlinux.org/index.php/Keyboard_configuration_in_Xorg#Using_localectl

Helder Max 2017-11-18 13:10

Tomas, any plan for localized ISOs like the ones in the Slackware Slax?
Can we expect that in the coming future?
Thank you.

Tomas M 2017-11-18 13:50

All the localizations were possible thanks to KDE, since it was localized. So I didn't have to translate things myself. But KDE is no longer included, so I doubt there could be localized versions of Slax in the future. Moreover there is almost nothing to be localized at the moment, since there are just 3 apps.

In all cases, Slax includes support for international input, so you can use fluxbox menu to select your keyboard mappings, and then you can type in your language without any issues. I made a poll some time ago and it was a result of that poll that people do not necessarily need Slax to speak their language, but they need to be able to write in their language. So this is the result :)

Yevhenii Tsybulskyi 2017-11-18 15:59

Tomas how add compress package like in old version ? How can i add new app in distro ?

Tomas M 2017-11-18 16:30

Additional software can be installed with apt command.

Николин Николов 2017-11-18 17:41

Hi !

How install slax 9 x64 on USB in slax 7 x32 environment ???

Thanks

Tomas M 2017-11-18 18:45

I would do the following:
1) mkdir /mnt/iso && mount -o loop slax9.iso /mnt/iso
2) mkdir /mnt/usb && mount /dev/sdb1 /mnt/usb # make sure to replace /dev/sdb1 by your usb device
3) copy /mnt/iso/slax to /mnt/usb, I don't remember the correct syntax for recursive cp command
4) cd /mnt/usb/slax/boot
5) sh bootinst.bat

Николин Николов 2017-11-18 20:04

All good , but the patient died :(
extract iso on usb device follow instruction
"sh bootinst.bat" and reboot
result :
"failed to load com32 file /slax/boot/vesamenu.c32"
try
"sh bootinst.sh"
same result :(

Pavel W 2017-11-18 20:37

I installed VLC player but I do not know how to start

Rodrigo Régio de Araujo 2017-11-18 23:51

How do I put the system to start as persistent mode automatically? I have to select the persistent mode every time when i use the slax.

Viktor F 2017-11-19 04:51

Persistent changes are lost after unproper "hard reboot" and moreover the system is unable to boot then. Deleting changes.dat helps, but it has something to be done to increase the reliability ot this feature.

// Sadly the modules located in this website are no longer updated. Are you going to maintain and renew some of them? Building a system from separated blocks is the key idea of this distro

Alexandru-Ionut Chiuta 2017-11-19 08:05

@Viktor F - You may try to install apps in AppImage format, as they work on any Linux distro - https://appimage.github.io/apps/

There are more "Linux apps that run anywhere" packaged in AppImage format - https://appimage.org/ . For example, Etcher is a great app used to burn images to SD cards & USB drives, safely and easily. You can find the AppImage in the ZIP archive of Etcher for Linux downloaded from the developer's website - https://etcher.io/.

Alexandru-Ionut Chiuta 2017-11-19 16:11

I am testing some of the 168 AppImages available at https://bintray.com/probono/AppImages where are listed some updated apps, like Firefox 57.0 ( https://bintray.com/probono/AppImages/Firefox#files ) and Arduino_IDE ( https://bintray.com/probono/AppImages/Arduino_IDE#files ), which can be downloaded from the Files section.

The installation is simple, just change the permissions of each downloaded AppImage to "read and write" and launch the file to install the software.

So, we can enjoy the latest versions of some apps using AppImages!

p. Trinx 2017-11-20 16:16

Hello,
Ok if I use fat32 it works but if I use ext4 It always stop "looking for slax ..." and reboot.
How can I use the ext4 only for save changes keeping the slax base in fat32; using 2 partitions in one pen usb?

Eddie WatNou 2017-11-21 19:16

@Pavel W type
echo -e "Video Player;/usr/share/icons/hicolor/128x128/apps/vlc.png;vlc\n" >> /etc/xlunch/entries.dsv

or edit /etc/xlunch/entries.dsv manually and add the following line:
Video Player;/usr/share/icons/hicolor/128x128/apps/vlc.png;vlc

The first part is the title, then icon and then the command.
(Make sure there are no empty spaces between the entries otherwise only the last items will load.

Ferenc 2017-11-21 21:05

Persistence works for me on ext3 or fat32 filesystem, however it does not work on ext4.

lucbertz 2017-11-22 11:07

And it does not work on NTFS, even after ntfs-3g installation.
Should some filesystem packages be integrated in initrfs.img or vmlinuz?