Search Results for 'chown'

Forum Forums Search Search Results for 'chown'

Viewing 15 results - 91 through 105 (of 118 total)
  • Author
    Search Results
  • #24392
    Member
    CalY

      Thank you for detailed explanation. The chmod/chown commands were what was looking for.

      #24367
      Member
      Xecure

        So, confirm if this is true:
        – You are using a live environment of antiX 17 ?
        – You boot it up.
        – You later connect the Hard drive USB device.
        – This USB device has a JFS partition?
        – When mounted, you only have read permissions but no write permissions.
        – You want wright permissions without having to login your user as root.

        Easy workarounds for all window managers (Three different options – have to do each time): Load antiX the same as before (normal user)

        a) For ROX Filer
        Go to any Terminal emulator (lxterminal for example)
        sudo rox-filer
        That will open ROX FM as “root”. Navigate to your media device. Now all read/write actions can be performed.

        b) With SpaceFM
        Open SpaceFM
        Up in the menu, select File > Root Window
        A new SpaceFM root window will pop up. You can navigate to your USB and do whatever you want there.

        c) Edit as root (only for editing files. Works in SpaceFM)
        Open the USB folder as normal user. Right click the file you want to edit. Open > Edit as Root
        (to change what editor it uses as default, in SpaceFM go to View > Preferences > Advance > Root’s Editor and change leafpad for your preferred editor)

        For Firefox, simply copy the files you download from ~/Downloads to you USB device using method a or b.

        Terminal solution for writing NEW files as normal user
        Once the device is mounted check to see its path. For example /media/device-name
        Go to terminal and give your user rights to write

        sudo chmod 0774 /media/device-name
        sudo chown username:users /media/device-name

        You will have to change username for your username and users for whatever group you want. For example, on live system with persistence it would look like:
        sudo chown demo:demo /media/device-name
        You will have to do this each time the device is mounted. You can save it a script and execute it each time.

        For a permanent solution (only for installed and persistent systems), you will have to add the device UUID (you get it from sudo bkid -o full) to /etc/fstab so that it mounts in /mnt/device-name with right permissions. You would then create the /mnt/device-name folder (mkdir) and give it the same permissions (previous script). I don’t know how to make it automount from there, so I will not attempt to explain. My tests only allowed me to create this mount point but I had to mount manually each time. Probably someone more knowledgeable can explain how to make it automount.

        Next time, start the question giving all the data. The problem you are experiencing is because you are using a USB device formatted as JFS. Someone more knowledgeable would have answered already your query, but because we had so little information, you had to wait until I tested it myself. I am a newbie mounting complicated stuff, as the partition formats I handle always automount with no write restrictions. To test if the solutions proposed worked, I formatted a USB device to this JFS partition format. My test show that this works for me, so it should also work for you.

        I hope this helps pave a path to a better antiX future.
        Good luck in your endeavors!

        antiX Live system enthusiast.
        General Live Boot Parameters for antiX.

        #21110

        In reply to: Blank screen at boot

        Member
        zeh

          Thanks linuxdaddy!

          “chown -R axTest:axTest /media/home/axTest” (actually “chown -R axTest:axTest /home/axTest”) did change the ownership of everything in my home folder.

          After having checked if the change had been done, I rebooted.

          Still got the blank screen. Ctrl+Alt+F1 as usual, and I get the system in text mode as usual.

          Logged in and tried “startx” (so, without sudo) just to see what would happen. And what happened was icewm started as before when I used “sudo startx” (it started in “Debian mode” I guess — no background image), but… it got frozen. The mouse didn’t work and I couldn’t open the menu by any other means (i.e. by the key bindings).

          Hard shutdown and start again, this time using “startx /usr/local/bin/desktop-session icewm” as Dave said (again, no sudo anymore). And I got icewm in “antiX mode” (antiX background image), but… frozen as well. Mouse not working and couldn’t open the menu with any key binding.

          So, it looks like we managed to get one more step forward, but without having reached the end of the line so far.

          And now it doesn’t look like I have a permissions issue anymore. I may very well be wrong, though, since I don’t know what is causing the freezes.

          EDIT:
          “startx /usr/local/bin/desktop-session icewm” “startx /usr/local/bin/desktop-session rox-icewm” and “startx /usr/local/bin/desktop-session rox-fluxbox” all open the respective wm, frozen.

          “startx /usr/local/bin/desktop-session sapcefm-icewm” and “startx /usr/local/bin/desktop-session spacefm-fluxbox” do not open the wm, just return the prompt in the text mode session after printing some lines of text, the last of whose reads:
          “waiting for X server to shutdown (II) Server terminated successfully (0). Closing log file.ession/logxinit: connection to X ser”

          It looks like the text in the line goes further but cannot be seen for getting out of the screen.

          Noticed “log file.ession/logxinit” where the bit “ession” looks like a corruption of the word “session”.

          • This reply was modified 4 years ago by zeh.
          • This reply was modified 4 years ago by zeh.
          • This reply was modified 4 years ago by zeh.
          #21071

          In reply to: Blank screen at boot

          Anonymous

            as root you could try to use the “chown” command and recusively
            change the permissions to your user. something like:

            chown -R axTest:axTest /media/home/axTest

            from the the command prompt and see if that helps.

            #19078
            Anonymous

              clarifying what I had tested, in virtualbox:
              pristine antiX-17.3.1_x64-full.iso ( but /etc/lsb-release states DISTRIB_DESCRIPTION=”antiX 17.2.1″ )

              from terminal:
              /usr/local/bin/menu_manager.sh

              The app launches and, upon clicking “Personal”, the terminnal output shows
              mkdir: cannot create directory ‘/home//.local'” Permission denied
              chown: cannot access ‘/home//.local/share/applications/TCM’: No such file or directory

              The app allows us to continue.
              Click “Add”, choose an item to add, and upon clicking “OK”, terminal output shows
              /usr/local/bin/menu_manager_personal.sh: line 483: /home//.local/share/applications/TCM…
              filenameofselecteditem.desktop: No such file or directory
              chown: cannot access… no such file or directory

              FWIW, identical result with the as-shipped ISO… and after apt full-upgrade has been performed

              Running app from the menu works

              aha, previously I hadn’t found a desktop menu item for “Menu Manager”.
              Rechecking today, I found it (Preferences) submenu, but only after choosing a “small” theme variant.
              With default theme, that item and quite a few others (SystemTools) were displaying offscreen
              and “scroll to see more” (seriously, not sarcasm) didn’t occur to me.

              ^———- Yes, launched from the desktop menu, “Menu Manager” is working properly.
              (note: full-upgrade has been performed. I haven’t retested this booting from as-shipped ISO)
              Also tested today, launching “Menu Manager” via ControlCenter and that too is working properly.

              #18020
              Anonymous

                An icewm theme may provide a custom “app”, folder”, and “xterm” icon for use in the menu.
                icewm loads these, if present, from /usr/share/icewm/themes/*/icons

                My icons are inside the /usr/share/icewm/icons folder, just as in antiX, but they still don’t display in the start menu.

                My problem is: “Within your ~/.icewm/menu file, notice that ONLY A SUBSET OF ITEMS represented in the menu ARE MODIFIABLE.” and “iceWM is hardcoded to display”.

                HOW DO I MODIFY THAT HARDCODED, NOT USER MODIFIABLE SUBSET OF ITEMS?

                Let us suppose you have selected an icewm theme named “silvertime”.
                As soon as you made that choice, icewm recorded that configuration detail
                by writing into file ~/.icewm/theme
                a line declaring
                Theme=”silvertime/default.theme”

                Each time iceWM starts, it reads the file ~/.icewm/theme
                and based on what it reads herein ( Theme=”silvertime/default.theme” )
                it checks the content of the directory /usr/share/icewm/themes/silvertime/icons/
                to determine whether these files exist:
                /usr/share/icewm/themes/silvertime/icons/app_16x16.xpm
                /usr/share/icewm/themes/silvertime/icons/folder_16x16.xpm
                /usr/share/icewm/themes/silvertime/icons/xterm_16x16.xpm

                That’s it. AFAIK, that is the limited customization extent iceWM supports for those “hardcoded” menu items
                (settings, focus, bullet displayed for the currently selected item within a submenu…)

                Can you tell me why my vanilla Devuan-IceWM is missing those 8 icons that we get inside antiX?

                Because it is using a different theme?

                If you were to copy directory+contents
                /usr/share/icewm/themes/silvertime/
                from an antiX system into a Devuan system (or from Devuan system to antiX system)
                we should expect that theme will be displayed identically on either system.

                .
                =================

                a separate detail, mentioned for the sake of completeness:

                On either system, you may override the “global” theme definition files by (for example):
                mkdir ~/.icewm/themes/silvertime
                cp /usr/share/icewm/themes/silvertime/*
                sudo chown -R myusername:myusername /usr/share/icewm/themes/silvertime/*

                #16939
                Anonymous

                  I would first check whether the earlier “adventure” caused root ownership of any of your files:
                  find /home/russelb -user root

                  To fix, if any are found (consider which files have become root-owned,
                  and which actions during your earlier root login were likely involved, for your future reference):
                  sudo chown -R russellb:russellb /home/russellb

                  Second, I would (and suggest you do the same here) revisit the Debian docs regarding dotfiles.
                  https://wiki.debian.org/DotFiles
                  https://wiki.debian.org/EnvironmentVariables
                  The antiX userconfig defaults, as provided in /etc/skel , I don’t recall any “how/when .bashrc is sourced” differences, compared to stock debian. (If you discover/notice any proprietary handling, post back to give future readers a heads-up, eh)

                  The antiX distribution almost certainly prepopulates a different set of userconfig envvars compared to stock debian.

                  The antiX distribution permits, but does not encourage, “root login” and prepoulates very few of the /root configfiles ~~ expecting/necessitating the “I wannabe root” users to accept responsibility for setting up rootuser config themselves.

                  Third, a point of confusion:
                  You mentioned “shell”. Idunno whether the context (of your testing/reporting, above) is a tty console or a terminal emulator.
                  If it’s a terminal emulator, which program? (glad to hear, but just asking rhetorically)
                  If roxterm is installed, within its “preferences” you can configure so that it will run a login shell for you by default (if that suits you).
                  The lxterminal program, I don’t recall that it enables storing that detail as a permanent election. Instead (man lxterminal) we can launch it with commandline option.

                  ^—- when you tested changes to your .bashrc et al, maybe you hadn’t logged out/in (nor invoked a new login shell within xyzterm) before testing the result

                  Hearing that the “shell” hung during your testing leads me to wonder whether you introduced some syntax error(s) while editing your .profile, .bashrc

                  Rather than immediately contemplating a full reinstall, try replacing (diffing, instead, and selectively merging changes, would probably be more enlightening toward understanding what/where any error(s) had been introduced) your russellb config files with copies from /etc/skel

                  When experimenting/tinkering with dotfiles, it’s safer to temporarily create an additional user account ~~ mess with the dotfiles, and perform other experimentation while logged in as the throwaway user. Or keep that other account onhand for future testing (a spartan homedir occupies only ~200kb)

                  #13661
                  Anonymous

                    It will be difficult for others to diagnose the nature and degree of the brokenness unless you post a step-by-step list of the changes you made.

                    ==================
                    “no default demo user found on the system”
                    SLiM provides an entrybox where you can (should) now supply “grenouille” as the login name.
                    Possibly you had elected “autologin”…

                    From console, you can
                    sudo cp /etc/slim.conf /etc/slim.conf_backup
                    sudo nano /etc/slim.conf
                    and
                    Find the line that mentions “autologin”. Replace yes with no (can revert this later, if desired)
                    Find the line that mentions default_user. Relace demo with grenouille
                    Ctrl+X to exit nano and save.
                    ===================

                    Toward repairing the remaining problems, I’ll suggest
                    sudo adduser grenouille
                    sudo addgroup grenouille grenouille
                    (the above 2 commandlines may require some fiddling, may be unnecessary if the target username and groupname already exist)
                    cd /home/grenouille
                    sudo chown grenouille:grenouille *.*
                    sudo chown grenouille:grenouille .*
                    sudo chown grenouille:grenouille *
                    (The first chown pattern may suffice. For good measure, do all 3)
                    then
                    grep -inr ‘demo’
                    …and prepare to spend some time replacing any hardcoded references to “demo” within the username // pathname strings of the configuration files for your various applications. In particular, mozilla firefox (its sqlite databases, and its user.js, and conf files of individual addons) may contain a lot of now-stale pathstrings.

                    #10960
                    Anonymous

                      “ability to edit as root in the Rox-filer is gone”

                      Replacing your user’s rox config files with fresh copies may fix. Copy the contents of /etc/skel/.config/rox.sourceforge.net/ROX-Filer/
                      into your ~/.config/rox.sourceforge.net/ROX-Filer/
                      and sudo chown -R youruser:youruser ~/.config/rox.sourceforge.net/ROX-Filer/*
                      (spot check to verify this suggested command has also changed the permissions on any .dotted filenames)

                      #10927
                      Anonymous

                        rox helpdocs mention something like “if your windows have transparency (meaning: a compositor is running) the rox panel can have transparency”.

                        Maybe your rox configuration files are corrupted? To rule out that possibility, try this: create another fresh user account then login as that new user. If the new user’s rox panel menu is (yes) broken, reinstall the desktop-defaults-rox package. Afterward create yet another user account, login, and check whether his rox panel menu is alright.
                        If working for other user accounts, overwrite youruser’s config files with fresh copies
                        cp /etc /skel /.config /rox.sourceforge.net /ROX-Filer/* ~/.config/rox.sourceforge.net/ROX-Filer
                        chown yourusername:yournusername cp /etc /skel /.config /rox.sourceforge.net /ROX-Filer/*
                        and afterward try launching rox panel and recheck availability of the panel menu

                        The desktop menus provided by Xfce and mate environments probably do not respect or recognize all of the entries in the stock antiX desktop menu. The desktop menu entry “toggle rox panel” might be absent, but you can still start it manually but you might still wind up with some confusing hassle running it in those environments so better to just install some other panel app or dock app (docky?)(fbpanel?)

                        Moderator
                        Brian Masinick

                          Momentarily, I can see a console screen full of startup information (“Welcome to AntiX”, etc.) and a login prompt, before the login splash screen reappears.
                          The image displayed is a deserted station platform and a train with unnatural light beams.

                          What next?

                          I’m not sure that any of us have actually solved the fundamental problem, but my conjecture on this, based on past experiences, though limited by not actually witnessing what is taking place, is that two things are likely to either be potential causes of the problem, or at least able to reduce potential cause, which will help find the actual culprit:

                          1. One of the first things I check – first at the user account level, then throughout the filesystems (being MUCH more careful about changing ANYTHING at the file system level unless I’m willing to scrap and replace the system entirely). Sometimes, something as simple as: sudo chown -R myuser:mygroup $HOME – that is making sure that ALL files within my user account are actually owned by me and managed by my groupID – solves my own most common problems; try it to see if it helps in any way for you.

                          2. The hardware you are using – for whatever reason – is not properly configured or supported by the installation or something got accidentally or indvertently altered during installation, configuration, or day to day use. If other distributions work fine and you know something about where certain capabilities are stored, you can compare configuration and setup scripts and data files to see if anything really obvious is changed. You can also save a particular file – copy it or back it up somewhere, then copy another distribution’s file in it’s place. If it fixes the issue, keep it; otherwise restore the original; make one change at a time. That’s another way to hack your way to a solution. The more practice you have doing this, the better you’ll be able to give an educated guess about what is wrong.

                          If you back up the entire system plus a separate backup of specific changes you make, you can get pretty crazy with what you change, yet recover from it if it doesn’t work. Of course you can also trash the entire setup and start over; unless you have a lot of difficult to replace information, it may be better to do this, copying back in the files and features you need. Trying out a completely replaced image and cleaned out data may help isolate issues too. I hope this helps with your diagnosis.

                          • This reply was modified 5 years ago by Brian Masinick.

                          --
                          Brian Masinick

                          Member
                          rob

                            The btrfs filesystem’s compression feature is quite handy to shoehorn things onto the small drives in early netbooks and other older systems.

                            There are three compression modes available in btrfs. Lzo is fast but the compression is not great. Zlib compresses very well but it is comparatively slow. Zstd is available from kernel 4.14 onwards and compresses about as well as zlib, and about as fast as lzo. (Zstd has one big disadvantage in that grub will not boot from a drive that is using zstd on the files contained in /boot/).

                            I run btrfs with zstd compression on my Asus eee pcs with their tiny and sluggish 4 GB SSDs. On a system with such small and slow storage, it helps spending less time reading and writing from the drive, albeit with a slight increase in cpu usage during access. It will however be slower to do the initial install as it tries to compress every file.

                            This modified version of the cli-installer from 17.1 has a couple of extra options for btrfs available in the file system selection menu.

                            There are only two very minor changes involved, both optional and in addition to a standard btrfs install.

                            The mount options include compress-force=zlib during the installation and in the fstab it creates, enabling and selecting the compression type.
                            # mount -o defaults,relatime,compress-force=zlib

                            Optionally, during the filesystem creation, options are better tuned to small hard drives (<~16GB). This allows any sector to be used by data or metadata, (preventing erroneous drive-full errors which can occur on small drives otherwise).
                            # mkfs.btrfs -f -M -O skinny-metadata /dev/sdX

                            Here are the results comparing installation of antiX-full to a 4GB drive. This is using the modified cli-installer, otherwise installed as standard from antiX-17.1-386-full.iso.

                            Ext 4
                            Filesystem	1K-blocks	Used	Available	Use%	Mounted on
                            /dev/sda1	4061888		2991020	844820		78%	/mnt
                            
                            Btrfs 
                            Filesystem	1K-blocks	Used	Available	Use%	Mounted on
                            /dev/sda1	4061888		2972980	1037839		75%	/mnt
                            
                            Btrfs with zlib compression
                            Filesystem	1K-blocks	Used	Available	Use%	Mounted on
                            /dev/sda1	4193280		1452200	2557720		37%	/mnt
                            
                            Btrfs with zlib compression & small drive options
                            Filesystem	1K-blocks	Used	Available	Use%	Mounted on
                            /dev/sda1	4193280		1345712	2858836		33%	/mnt

                            I also decided to see if it was possible to get a complete install of antiX 17.1-full with all subsequent updates installed onto a 1.5 GB drive, in a usable state.

                            After the initial installation, packages were updated individually using apt list –upgradable, then apt install for each one. (Some of them will pull others along with them). This was necessary as with the number and size of the updates available, apt upgrade as one operation would have filled the drive. Then the kernel was upgraded to 4.15.14 from the antiX repo. Finally, I installed bleachbit to remove the localizations that i did not require.

                            In the end, it got there with a touch of room to spare, at around 1.2 GB used for the install and around 300 MB available:

                            Filesystem	1K-blocks	Used	Available	Use%	Mounted on
                            /dev/sda1	1534976		1210212	337056		79%	/

                            Although the 1.5GB drive was just as an exercise, this sort of install is useful on early netbooks with their minimal storage, and other older hardware with small slow drives. Once grub is updated to support zstd, it will bring easy performance benefits as well as size savings.

                            Updated cli-install

                            #!/usr/bin/env bash
                            # cli-installer for antiX
                            # written by Burt Holland
                            # heavily edited by anticapitalista
                            # btrfs tweaks for small systems added by rob
                            
                            TEXTDOMAINDIR=/usr/share/locale
                            TEXTDOMAIN=cli-installer
                            
                            #Default
                            DISTR0=antiX-17
                            LIVEUSER=demo
                            
                            ##functions
                            #title
                            #header
                            #help_text
                            #gethome
                            #getroot
                            #repartition
                            #setfs
                            #setpw
                            #yn(yes/no)
                            #getfs
                            #encrypt
                            
                            title() {
                            echo -ne "\e[32m"
                            echo $"CL installer for $DISTRO"
                            echo $"Version 4.1 2017/12/27"
                            echo -ne "\e[0m"
                            echo ''
                            }
                            
                            header() {
                            echo -ne "\e[36m"
                            echo $"Requirements for minimum* installation:"
                            echo -ne "\e[0m"
                            echo ''
                            echo $"antiX-full: hard-disk 4.0GB*  RAM 64MB"
                            echo ''
                            echo $"antiX-base: hard-disk 3.0GB*  RAM 48MB"
                            echo ''
                            echo $"antiX-core: hard-disk 1.0GB*  RAM 48MB"
                            echo ''
                            echo $"antiX-net:  hard-disk 0.7GB*  RAM 48MB"
                            echo ''
                            echo $"Make sure you are connected to "
                            echo ''
                            echo $"the net BEFORE running this installer"
                            echo ''
                            }
                            
                            help_text() {
                            echo $"Usage: cli-installer [drive]"
                            echo $"Where drive is the name of the drive $DISTRO is to be installed on."
                            echo $"   For example: cli-installer sdb"
                            echo $"The default is correct if the computer has only one drive."
                            echo ''
                            # tips for this version
                            echo -ne "\e[36m"
                            echo $"Pre-installation tips:"
                            echo -ne "\e[0m"
                            echo ''
                            echo $"Set language at the boot screen by pressing F2"
                            echo $"or by adding the line lang=xx where xx is your language code."
                            echo $"eg lang=gr for Greek."
                            echo ''
                            echo $"Set timezone at the boot screen by pressing F3"
                            echo ''
                            echo $"Use kbd=dvorak for dvorak keyboard before installing"
                            # end tips
                            echo ''
                            echo $"Press F1 at the boot screen for Help and list of cheatcodes for live use."
                            }
                            
                            gethome() {
                            ans=1
                            while [[ "$ans" -ne 0 ]]
                            do
                            read -p $"/home partition (hda1, sda2, etc): " hdrv
                            echo ''
                            if [[ ("$hdrv" == "$rdrv") || !( -e "/dev/$hdrv" ) ]]
                              then echo $"$hdrv invalid. Retry:"
                              else ans=0
                            fi
                            done
                            }
                            
                            getroot() {
                            ans=1
                            while [[ "$ans" -ne 0 ]]
                            do
                            read -p $"Root partition (hda1, sda2, etc): " rdrv
                            if [[ "$rdrv" > "hd" && "$rdrv" < "he" ]]; then rpre=hd
                              elif [[ "$rdrv" > "sd" && "$rdrv" < "se" ]]; then rpre=sd
                              else rpre=x;
                            fi
                            if [[ !("$rpre" = "x") ]]
                              then 
                              gdrv1=-1
                              for var in "a" "b" "c" "d" "e" "f" "g" "h" "i" "j" "k"
                              do
                             if [[ "$rdrv" > "$rpre$var" ]]
                              then
                              gdrv1=$((gdrv1+1))
                              gdrv="$var"
                             fi
                             done
                             gpart=-1
                             var1=-1
                             for var in "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19"
                             do
                             var1=$((var1+1))
                             if [[ "$rdrv" == "$rpre$gdrv$var" ]]
                              then
                              gpart=$var
                              gpart1=$var1
                             fi
                             done
                            fi
                            if [[ "$rpre" = "x" || "$gdrv1" -lt 0 || "$gdrv1" -gt 18 || "$gpart1" -lt 0 ]]
                              then echo $"$rdrv invalid. Retry"
                              else ans=0
                            fi
                            done
                            }
                            
                            repartition() {
                            if [[ -n "$1" ]]
                              then cfdisk /dev/$1
                              else cfdisk
                            fi
                            }
                            
                            setfs() {
                            umount /dev/$1 > /live/aufs/dev/null 2>&1
                            echo $"Available file systems for $1 are:"
                            echo "
                            1)ext2 
                            2)ext3 
                            3)ext4 
                            4)jfs 
                            5)xfs 
                            6)btrfs 
                            7)btrfs with zlib compression
                            8)btrfs with zlib compression
                              optimized for small drives
                            9)reiserfs"
                            echo ''
                            ans=1
                            while [[ $ans -ne 0 ]]
                            do
                            read -p $"Enter your choice 1-9: " fs
                            if [[ "$fs" == "" ]]
                              then fs=ext4
                            fi
                            ans=0
                            echo $"You have chosen $fs for $1"
                            echo ''
                            mntopt="defaults,relatime"
                            case $fs in
                            1) mkfs.ext2 /dev/$1 > /live/aufs/dev/null 2>&1;;
                            2) mkfs.ext3 /dev/$1 > /live/aufs/dev/null 2>&1;;
                            3) mkfs.ext4 /dev/$1 > /live/aufs/dev/null 2>&1;;
                            4) mkfs.jfs -q /dev/$1 > /live/aufs/dev/null 2>&1;;
                            5) mkfs.xfs -f /dev/$1 > /live/aufs/dev/null 2>&1;;
                            6) mkfs.btrfs -f /dev/$1 > /live/aufs/dev/null 2>&1;;
                            7) mntopt="defaults,relatime,compress-force=zlib"
                            mkfs.btrfs /dev/$1 > /live/aufs/dev/null 2>&1;;
                            8) mntopt="defaults,relatime,compress-force=zlib"
                            mkfs.btrfs -f -M -O skinny-metadata /dev/$1 > /live/aufs/dev/null 2>&1;;
                            9) mkreiserfs -q /dev/$1 > /live/aufs/dev/null 2>&1;;
                            10) mkfs.reiser4 -f -y /dev/$1 > /live/aufs/dev/null 2>&1 
                            
                            echo $"Ignore any 'barrier' lines";;
                            *) echo $"$fs invalid. Retry:"; ans=1
                            esac;
                            done
                            }
                            
                            setpw() {
                            ans=1
                            while [[ $ans -ne 0 ]]
                            do
                            if (chroot /media/$rdrv passwd $1)
                              then ans=0
                              else
                              echo -ne "\e[31m"
                              echo $"Passwords are not identical. Retry:"
                              echo -ne "\e[0m"
                            fi
                            done
                            }
                            
                            yn() {
                            x=1
                            while [[ "$x" -eq 1 ]]
                            do
                            x=0
                            read -p "$*? "
                            if [[ ("$REPLY" > "x~" && "$REPLY" < "z" ) || ("$REPLY" > "X~" && "$REPLY" < "Z") ]]
                              then ans=1	# yes
                              elif [[ ("$REPLY" > "m~" && "$REPLY" < "o" ) || ( "$REPLY" > "M~" && "$REPLY" < "O") ]]
                              then ans=0	# no
                              elif [[ -z "$REPLY" ]]
                              then ans=-1	# default
                              else
                              x=1
                              echo $"Invalid; retry:"
                            fi
                            done
                            }
                            
                            getfs() {
                            fs1=$(blkid /dev/$rdrv $a|sed -e "s/.*TYPE=\"//"|sed -e "s/\".*//")
                            fs2=$(blkid /dev/$hdrv $a|sed -e "s/.*TYPE=\"//"|sed -e "s/\".*//")
                            }
                            
                            ##End of functions
                            
                            #Run Help
                            if [[ "$1" == "-h" || "$1" == "--help" ]]
                              then
                              help_text
                              echo ''
                              read -p $"Press Enter to exit this script."
                              exit
                            fi
                            
                            # Run as root check
                            if [[ $UID -ne 0 ]]
                              then
                              echo -ne "\e[31m"
                              echo $"Please run this script as root."
                              echo -ne "\e[0m"
                              exit
                            fi
                            
                            # Make sure /live/aufs/dev, /live/aufs/sys, /live/aufs/proc exist when starting script
                            mkdir -p /live/aufs/dev /live/aufs/sys /live/aufs/proc
                            # Make sure fstab is ok and start swap - (needed for antixsnapshot)
                            make-fstab
                            swapon -a
                            # Show requirements
                            kernel="-$(uname -r)"
                            echo ''
                            header
                            echo ''
                            # Repartition or not and set file up system via cfdisk
                            yn $"Do you want to repartition the disk (y/N)"
                            if [[ $ans -eq 1 ]]
                             then
                               repartition $1
                               echo '====';
                               echo ''
                               getroot
                               echo ''
                               setfs $rdrv
                             else
                               echo ''
                               getroot
                               echo ''
                               echo $"Deleting the contents of the $rdrv partition."
                               echo $"This may take some time. Please wait...."
                            fi
                            mkdir /media/$rdrv > /live/aufs/dev/null 2>&1
                            mount -o $mntopt /dev/$rdrv /media/$rdrv > /live/aufs/dev/null 2>&1
                            rm -r /media/$rdrv/* > /live/aufs/dev/null 2>&1
                            echo ''
                            # Set up separate /home and mount on /media/$hdrv
                            yn $"Use separate '/home' partition (y/N)"
                            if [[ "$ans" -eq 1 ]]
                              then
                              gethome
                                if [[ !(-e /media/$hdrv) ]]
                                then mkdir /media/$hdrv
                                fi
                                yn $"Is $hdrv a new '/home' partition (y/N)"
                                if [[ "$ans" -eq 1 ]]
                                  then
                                  hmtp=2
                                  echo ''
                                  yn $"Set file system for $hdrv  (y/N)"
                                    if [[ "$ans" -eq 1 ]]
                                    then
                                    setfs $hdrv
                                    fi
                                    mount /dev/$hdrv /media/$hdrv > /live/aufs/dev/null 2>&1
                                    rm -r /media/$hdrv/* > /live/aufs/dev/null 2>&1
                                    else
                                    hmtp=1
                                    mount /dev/$hdrv /media/$hdrv
                                fi
                                else
                                hmtp=0
                            fi
                            getfs
                            #Install grub-pc and clean out downloaded debs
                            yn $"Are you running antiX-net (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            echo ''
                            echo $"Time to download grub-pc, locales, keyboard-configuration, console-setup, console-data, lsb-release, sysv-rc-conf"
                            apt-get update && apt-get -y install grub-pc locales keyboard-configuration console-setup console-data lsb-release sysv-rc-conf
                            apt-get -y clean
                            fi
                            #We are now in $rdrv
                            cd /media/$rdrv
                            echo ''
                            echo $"antiX will now be copied to $rdrv."
                            echo $"This may take some time. Please wait...."
                            cp -a /live/aufs/* .
                            
                            #set up fstab
                            echo '# Pluggable devices are handled by uDev, they are not in fstab' > etc/fstab.new
                            echo "/dev/$rdrv / $fs1 $mntopt 0 1"  >>  etc/fstab.new
                            grep swap etc/fstab >> etc/fstab.new
                            if [[ "$hmtp" -gt 0 ]]
                              then
                              echo "/dev/$hdrv /home $fs2 defaults,relatime 0 2" >> etc/fstab.new
                              arg1=$hdrv
                              else
                              arg1='xxxx'
                            fi
                            echo '# Dynamic entries below' >> etc/fstab.new
                            grep -v '#' etc/fstab|grep -v swap|grep -v proc|grep -v devpts|grep -v $rdrv|grep -v $arg1 >> etc/fstab.new
                            rm etc/fstab
                            mv etc/fstab.new etc/fstab
                            cp etc/group etc/group.bak
                            cp etc/gshadow etc/gshadow.bak
                            echo $"File copy done"
                            echo ''
                            yn $"Install GRUB on MBR (Y/n). No will install to root partition"
                            if [[ $ans -eq 0 ]]
                              then grub=$rdrv
                              else grub=sd$gdrv
                            fi
                            
                            # Copy over non-live boot parameters to the installed system (FIX ME)
                            #cmdline=$(/live/bin/non-live-cmdline | sed -e 's/\\/\\\\/' -e 's/[|]/\\|/')
                            #[ $(uname -m) = x86_64 ] && cmdline="$cmdline"
                            #cmdline="quiet $cmdline"
                            #sed -r -i "s|^(GRUB_CMDLINE_LINUX_DEFAULT=).*|\1\$$cmdline|" /media/$rdrv/etc/default/grub
                            
                            #grub2 must set up bind mountpoints
                            # mount stuff so grub will behave (so chroot will work)
                            mount -o tmpfs --bind /dev/ /media/$rdrv/dev/ 
                            mount -o proc --bind /proc/ /media/$rdrv/proc/ 
                            mount -o sysfs --bind /sys/ /media/$rdrv/sys/ 
                            chroot /media/$rdrv grub-install --target=i386-pc --recheck --no-floppy --force /dev/$grub > /dev/null  2>&1 
                            chroot /media/$rdrv update-grub $grub > /dev/null  2>&1
                            #/sbin/make-fstab --install /media/$rdrv --mntpnt=/media > /dev/null  2>&1
                            chroot /media/$rdrv update-initramfs -u -t > /dev/null  2>&1
                            echo $"GRUB installed on ($grub)"
                            echo ''
                            chroot /media/$rdrv userdel $LIVEUSER
                            rm -r home/$LIVEUSER > /dev/null  2>&1
                            read -p $"Computer name (default is 'antix1')? " cnam
                            name=""
                            if [[ -n "$cnam" ]]
                              then
                              echo "$cnam" > etc/hostname
                              sed -i s/antix1/$cnam/ etc/hosts
                            fi
                            echo ''
                            echo $"Time to set up localisation"
                            echo $"System locale is set to ..."
                            chroot /media/$rdrv cat /etc/default/locale 
                            yn $"Do you want to set up system localisation (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            chroot /media/$rdrv dpkg-reconfigure locales
                            fi
                            echo ''
                            echo $"Time to set keyboard layout"
                            echo $"System keyboard is set to ..."
                            chroot /media/$rdrv cat /etc/default/keyboard 
                            yn $"Do you want to set up keyboard (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            chroot /media/$rdrv dpkg-reconfigure keyboard-configuration 
                            fi
                            echo ''
                            echo $"Time to set console layout"
                            echo $"System console is set to ..."
                            chroot /media/$rdrv cat /etc/default/console-setup
                            yn $"Do you want to set up console layout (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            chroot /media/$rdrv dpkg-reconfigure console-setup
                            fi
                            echo ''
                            echo $"Time to set timezone"
                            echo $"System timezone is set to ..."
                            chroot /media/$rdrv cat /etc/timezone 
                            yn $"Do you want to set up system timezone (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            chroot /media/$rdrv dpkg-reconfigure tzdata 
                            fi
                            echo ''
                            echo $"Choose which services to run"
                            yn $"Do you want to enable/disable startup services (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            chroot /media/$rdrv sysv-rc-conf
                            fi
                            echo ''
                            sleep 1
                            yn $"Is this a remastered/snapshot install (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                              # Write code to get buildfstab -r to start on first boot via rc.local (if user wants it?)
                              mv etc/rc.local etc/rc.local2
                              mv etc/udev/rules.d/90-fstab-automount.rules etc/udev/rules.d/90-fstab-automount.rules.live
                              cp usr/share/antiX/rc.local.install etc/rc.local
                              # (also)Remove live system if it exists
                              chroot /media/$rdrv dpkg -r live-init-antix 2>/dev/null
                              rm /media/$hdrv/$LIVEUSER 
                              umount -l /media/$rdrv
                              umount -l /dev/$hdrv
                              echo $"Installation of $DISTRO finished!"
                              echo ''
                              echo $"Reboot computer without CD to start program. ('reboot')"
                              exit
                            fi
                            sleep 1
                            echo $"Setting up user and root/admin accounts"
                            name=''
                            while [[ -z "$name" ]]
                            do
                            read -p $"Type in your default user name? " name
                            done
                            case $hmtp in
                            0)chroot /media/$rdrv adduser $name;;
                            1)echo '';echo $"Note: $hdrv must contain a folder named '$name'."
                            chroot /media/$rdrv adduser $name;;
                            2)chroot /media/$rdrv adduser $name;;
                            esac
                            echo ''
                            echo $"Type your Password for root:"
                            setpw root
                            sed -i "s/$LIVEUSER/$name/" etc/group
                            sed -i "s/$LIVEUSER/$name/" etc/gshadow
                            sed -i "s/$LIVEUSER/$name/" usr/share/slim/themes/antiX/slim-install.conf 2>/dev/null
                            yn $"Set autologin for $name: (y/N)"
                            if [[ $ans -eq 1 ]]
                              then
                            sed -i "s/#auto_login/auto_login/" usr/share/slim/themes/antiX/slim-install.conf 2>/dev/null
                            sed -i "s/#default_user/default_user/" usr/share/slim/themes/antiX/slim-install.conf 2>/dev/null
                            fi
                            # Copy live configurations to install. For all.
                            echo ''
                            echo $"Cleaning up"
                            /usr/sbin/live-to-installed /media/$rdrv
                            mv etc/rc.local etc/rc.local2
                            mv etc/X11/xorg.conf etc/X11/xorg.conf.live 2>/dev/null
                            cp usr/share/antiX/rc.local.install etc/rc.local
                            cp usr/share/slim/themes/antiX/slim-install.conf etc/slim.conf 2>/dev/null
                            chroot /media/$rdrv dpkg -r live-init-antix 2>/dev/null
                            cp -r etc/skel/.[a-zA-Z]* home/*/ 2>/dev/null
                            cp -r etc/skel/* home/*/ 2>/dev/null
                            if [[ $hmtp -gt 0 ]]
                              then
                                if [[ $hmtp -eq 2 ]]
                                then mv home/* /media/$hdrv
                                fi
                              rm -r home
                              mkdir home
                              cp -r /media/$rdrv/etc/skel/.[a-zA-Z]* /media/$hdrv/*/ 2>/dev/null
                              cp -r /media/$rdrv/etc/skel/* /media/$hdrv/*/ 2>/dev/null
                              chown -R $LIVEUSER.users /media/$hdrv/* 2>/dev/null
                            fi
                            chown -R $LIVEUSER.$LIVEUSER home/* 2>/dev/null
                            
                            rm -rf media/sd*
                            rm -rf media/hd*
                            rmdir live
                            umount -l /media/$rdrv/dev/
                            umount -l /media/$rdrv/proc/
                            umount -l /media/$rdrv/sys/
                            umount -l /media/$rdrv
                            if [[ "$hmtp" -ne 0 ]]; then umount -l /dev/$hdrv;fi
                            echo ''
                            echo $"Installation of antiX finished!"
                            echo ''
                            echo $"Reboot computer without CD to start program. ('reboot')"
                            • This topic was modified 5 years ago by rob. Reason: included cli-installer
                            #9582
                            Forum Admin
                            anticapitalista

                              Check the permissions of the /home folder.
                              If the are wrong, I suspect they are, then use chown to change them eg chown -R yourusername:yourusername /home

                              If that still doesn’t work, it may be better to re-install but with /home not on a separate partition,

                              Philosophers have interpreted the world in many ways; the point is to change it.

                              antiX with runit - leaner and meaner.

                              Anonymous

                                icewm is “picky”, in the sense that it demands that some of its config files must be chmod +x (else it ignores ’em).
                                If you copied ’em into place from another install, although the account username might be the same… the uid of the accounts may be different and, therefore the new “bubbabob” user account lacks u+x permission for those files.
                                cd ~
                                sudo chown -R yourusername:yourusername *
                                (and inspect the files within ~/.icewm/ and compare against the copies in /etc/skel/.icewm/ to see which should be +x)

                                #8305

                                In reply to: Live antiX-core

                                Member
                                andfree

                                  I added to the Xwrapper.config file this line:
                                  needs_root_rights=yes

                                  I also changed the ownership of .Xauthority file from “root:root” to “demo:demo”, because it had given this message:
                                  xauth: timeout in locking authority file /home/username/.Xauthority

                                  Then, I was able to start X as demo, but I was not able to start palemoon:
                                  Your Pale Moon profile cannot be loaded. It may be missing or inaccessible.

                                  I thought it as caused by having modified palemoon settings as root. I tried these commands:

                                  sudo chown -R demo:demo /home/demo/*
                                  sudo chown -R demo:demo /home/demo/.*

                                  After that, when trying “startx”, again:
                                  xauth: timeout in locking authority file /home/username/.Xauthority

                                  Then, I installed xterm and I was able to run X as demo. After that, I purged xterm, ran “sudo apt autoremove”, and still I’m able to run X as demo.

                                Viewing 15 results - 91 through 105 (of 118 total)