Slackware - InstallationThis forum is for the discussion of installation issues with Slackware.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
My good friend helped me (read: installed for me) 14.1 Slackware on a spare 2012 Toshiba laptop I had laying around. Installation seemed to work just fine.
However, while he was answering some of my questions, we discovered: there are folders missing in /root: there's no desktop folder, etc.
The only folders we see are : .config, .dbus, and .gnupg. The only files are .bash_history, .xinitrc, and .xsession
Any ideas? Do we need to add more files manually? Does it matter?
The content of /root as you see it is normal and there's no need to add files there: "root" being the "superuser" or the "admin" is not supposed to own many files, especially not those intended for the desktop as you are supposed to use it as a regular user, not as root. you files will go in /home/<your regular user name>, for instance /home/bignickel
So if not already done please use the command "adduser" to add an account for regular user. bignickel is an acceptable name for that user but you may choose another one if you prefer
You can accept the default proposed settings when asked, do add the additional groups as suggested by the program to be able to fully use your desktop.
Thanks for your quick reply. Yes, we've already created 'bignickel', and I'm in as that now creating these posts.
I will read the link you sent; it seems that your opinion is that we don't need any additional folders in /root. Hopefully this will be the case, as we're not sure what folders would need to be added for bash to work correctly (we assumed that it had been working fine all alonge)
Believe me, you don't need to fiddle with /root at all for your Slackware to work.
Out of curiosity, what makes you believe that you need something in /root that is not already there? For what purpose?
In any case, bash doesn't need anything special in /root. Furthermore, bash is used heavily to run all Slackware scripts, so if it missed something you would have found that already the hard way.
Last edited by Didier Spaier; 06-29-2015 at 04:14 PM.
Well, I noticed that there was no history being kept for Root user. Using the up arrow key only revealed the last 4 commands of that session (nothing I typed, but just startup commands for some media player).
What exactly should I see in the root home folder if the setup program configured correctly (both non-hidden and hidden files)?
My friend showed me his /root folder: it's full of the same kind of things that any user folder would have (desktop, documents, etc) and alot more files.
Well, I noticed that there was no history being kept for Root user. Using the up arrow key only revealed the last 4 commands of that session (nothing I typed, but just startup commands for some media player).
The last commands typed through the bash interpreter are kept in the file . bash_history that you have, as indicated in your first post. To see them just type:
Code:
history
Of course you will get different results whether you type it as root or as bignickel.
Quote:
What exactly should I see in the root home folder if the setup program configured correctly (both non-hidden and hidden files)?
Exactly those that you have, listed in your first post.
Quote:
My friend showed me his /root folder: it's full of the same kind of things that any user folder would have (desktop, documents, etc) and alot more files.
This is most probably because your friend uses his or her root account to do everything as if it were a regular user's account. This is a very bad idea for security reasons, unless your never access the internet and be sure you will never make a mistake in a command that could erase your files and render your system unasable. For an explanation see User and Group Management.
Last edited by Didier Spaier; 06-30-2015 at 02:01 PM.
Ok, if I'm reading you correctly, you're saying that the below is exactly what you have in your own /root folder, or at least you did when you first installed 14.1. Is that correct? You have nothing else besides these files and folders?
This is a list of everything I have in /root:
total 32
drwx--x--- 5 root root 4096 Jun 30 15:00 ./
drwxr-xr-x 22 root root 4096 Jun 25 14:19 ../
-rw------- 1 root root 431 Jun 29 14:08 .bash_history
drwxr-xr-x 3 root root 4096 Jun 26 13:03 .config/
drwx------ 3 root root 4096 Jun 25 13:16 .dbus/
drwx------ 2 root root 4096 Jun 16 17:45 .gnupg/
-rw-r--r-- 1 root root 1198 Jun 15 12:21 .xinitrc
-rwxr-xr-x 1 root root 1198 Jun 15 12:21 .xsession*
This, on the other hand, is what my friend has (btw: he never does anything in root; he always does everything in a user account):
Ok, if I'm reading you correctly, you're saying that the below is exactly what you have in your own /root folder, or at least you did when you first installed 14.1. Is that correct? You have nothing else besides these files and folders?
I already told you that three times. I am on the verge of loosing patience. If you don't trust my answers just stop asking.
Quote:
This, on the other hand, is what my friend has (btw: he never does anything in root; he always does everything in a user account):
This output makes very obvious that on sept 25 2013 your friend used his root account to start X, and probably a desktop. Maybe he didn't use his root account on the dektop much since then, but he did that day.
Also, he started X on June 11 of the current year, and used that to print something (or at least tried to) on his HP printer and used KDE or at least a KDE application as root the same day.
Last edited by Didier Spaier; 06-30-2015 at 03:26 PM.
Well, I noticed that there was no history being kept for Root user. Using the up arrow key only revealed the last 4 commands of that session (nothing I typed, but just startup commands for some media player).
What exactly should I see in the root home folder if the setup program configured correctly (both non-hidden and hidden files)?
My friend showed me his /root folder: it's full of the same kind of things that any user folder would have (desktop, documents, etc) and alot more files.
Your root account will keep history of the 'root' user. I like to use the console and maintain my systems as 'root'. I like to have my users setup;
Quote:
I like to provide my users with this;
Code:
sample .bash_profile;
~$ cat .bash_profile
#-----------------cut-----------------
# .bash_profile
#08-30-06 12:21
# Source .bashrc
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
#-----------------cut end--------------
Code:
cat .bashrc
#-----------------cut-------------------
#.bashrc
#08-30-06 12:20
# Add bin to path
export PATH="$PATH:$HOME/bin"
# Dynamic resizing
shopt -s checkwinsize
#
#save bash history so as to share
shopt -s histappend
PROMPT_COMMAND='history -a'
# Custom prompt
#PS1='\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
#08-29-06 11:40 gws
if [ `id -un` = root ]; then
PS1='\[\033[1;31m\]\h:\w\$\[\033[0m\] '
else
PS1='\[\033[1;32m\]\h:\w\$\[\033[0m\] '
fi
#
# Add color
eval `dircolors -b`
#Terminus is a very nice Unicode font for the Linux console
#02-02-12 gws
#from dugan's site http://duganchen.ca/writings/slackware/fonts/
#04-30-12 11:41 removed
#
#if [ $TERM = "linux" ]; then
# setfont ter-v16n
#fi
# User defined aliases
alias cls='clear'
alias clls='clear; ls'
alias ll='ls -l'
alias lsa='ls -A'
alias lsg='ls | grep'
alias lsp='ls -1 /var/log/packages/ > package-list'
alias na='nano'
alias web='links -g -download-dir ~/ www.google.com'
#08-29-06 11:50
#To clean up and cover your tracks once you log off
#Depending on your version of BASH, you might have to use
# the other form of this command
trap "rm -f ~$LOGNAME/.bash_history" 0
#The older KSH-style form
#trap 0 rm -f ~$LOGNAME/.bash_history
#-----------------cut end--------------
I let them modify to suit their needs.
Hope this helps!
The ~.bashrc has the prompt setup to identify the account type when you enter into the terminal/console. Where ~# identifies the 'rootuser' and ~$ idenfies a normal user so you will know at all times which is in use on that console. alias is a big plus when you want to use repeated abbreviated commands along with your history.
One special note as other members have identified; You need to use 'root' with caution since the superuser(root) is all powerful at the cli. You do not wish/want to trash your system by inadvertent command usage so you should always use caution when in a 'root' account. You do not want to run a DE as 'root' since this can open you to many issues/problems. I know some admins ignore this but will not relate to issue(s) they created while running a DE as root. 'superuser' is all powerful when it comes to your Gnu/Linux install. Treat it with care/caution!
Have fun & enjoy!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.