LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 11-15-2014, 06:18 AM   #31
kikinovak
MLED Founder
 
Registered: Jun 2011
Location: Montpezat (South France)
Distribution: CentOS, OpenSUSE
Posts: 3,453

Rep: Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154

Quote:
Originally Posted by sycamorex View Post
I know who she is but her statement is factually not true and might indicate her in-depth knowledge perhaps does not necessarily revolve around tiling window managers.
http://www.linux.com/learn/tutorials...nager-on-linux

http://www.linux.com/learn/tutorials...-linux-desktop

http://www.linux.com/learn/tutorials...sktop-on-linux
 
1 members found this post helpful.
Old 11-15-2014, 06:58 AM   #32
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,905

Rep: Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026
That just makes the comment even worse. She clearly has the knowledge to know that minimal environment users don't have to jump through hoops to launch stuff, but said it anyway!
 
1 members found this post helpful.
Old 11-15-2014, 07:49 AM   #33
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by kikinovak View Post
You do know that X should never ever be started as root?
On most distros, including Slackware, X is running as root anyways, so starting X from the root account is not the real problem. The problem is running a DE or WM as root, which results in starting any application as root. Just a minor nitpick.

Regarding tiling WMs, yes, they can greatly increase productivity, but they can be hard to learn. I familiarized myself with them by running XMonad in XFCE (instead of xfwm4) and nowadays use i3 (using the Slackbuild from sycamorex when installing it on Slackware). Tiling WMs are that convenient that I actually am really annoyed by overlapping windows and some other deficiencies of most floating WMs).
 
Old 11-15-2014, 09:31 AM   #34
sycamorex
LQ Veteran
 
Registered: Nov 2005
Location: London
Distribution: Slackware64-current
Posts: 5,836
Blog Entries: 1

Rep: Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251
Quote:
Originally Posted by GazL View Post
That just makes the comment even worse. She clearly has the knowledge to know that minimal environment users don't have to jump through hoops to launch stuff, but said it anyway!
I agree. The last sentence from her review of i3wm:

Quote:
i3 is wonderfully configurable. See man xev, man pactl, and the excellent and thorough i3 documentation to learn more about the myriad ways to customize i3 and make it super-fast and efficient.
So apparently now a minimalist wm can be super-fast and efficient. Somehow jumping through hoops to launch an application does not strike me as efficient. Carla, make up your mind.

I wouldn't bring up the whole thing but I know how undervalued and 'misunderstood' minimalist WMs (especially tiling ones) are. Not only is it hard to do first steps when you're not used to them. You just stare at blank screen and think how on earth can anyone do anything with it, let alone be super productive. Such, I'd say, irresponsible comments by respectable authors/journalists do not help the case. Whatever her reason for writing it, she clearly did disservice to WMs. If beginners read comments like that, they'll clearly be put off and might not even try using a lot of excellent window managers.

See how this one reads (a made up Eclipse review) LOL
Quote:
I don't care for the minimalist editors (vim/emacs) so beloved of certain dev teams that require all kinds of hoop-jumping just to type a character. I have work to do and I like having all my stuff a single click away.
 
Old 11-15-2014, 11:32 AM   #35
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Quote:
Originally Posted by GazL View Post
Yep, don't knock it until you try it.
hint: creative use of 'dmenu' is a game changer!
I already use dmenu but I'm curious if you could elaborate on that 'creative use'; might give me ideas.
 
Old 11-15-2014, 02:02 PM   #36
moisespedro
Senior Member
 
Registered: Nov 2013
Location: Brazil
Distribution: Slackware
Posts: 1,223

Original Poster
Rep: Reputation: 195Reputation: 195
Quote:
Originally Posted by T3slider View Post
I already use dmenu but I'm curious if you could elaborate on that 'creative use'; might give me ideas.
I'd like that too. I just use it the "default way", press ALT-P, type the software name, run it.
 
Old 11-15-2014, 02:56 PM   #37
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
dmenu can be used in many different ways. For example, i3 can integrate it into a parser for .desktop files, so that only applications will be shown that would have a menu entry in a DE.
For other ideas how it can be used look at this thread in the Arch forum: https://bbs.archlinux.org/viewtopic.php?id=80145
 
1 members found this post helpful.
Old 11-16-2014, 04:56 AM   #38
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,905

Rep: Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026Reputation: 5026
By default the app launcher script that comes with dmenu just scans the path and lists everything executable. I find that a bit excessive and it actually gets in the way as there are just too many options. As Tobi has said there are scripts that will parse .desktop files, but I prefer just to keep a small list of my favourite apps in a ~/.dmenurc and use this instead:
Code:
#!/bin/sh
#
#  Script to call dmenu from within dwm.
#    ~/.dmenurc contains list of menu entries

if [ -f ~/.dmenurc ] ; then
   if cmd=$(dmenu "$@" < ~/.dmenurc) ; then
      exec /bin/sh -c "${cmd}"
   fi
fi
But that's not really what I'm talking about. You can build your whole environment around dmenu.
Examples:
Stick this in your bashrc, and you've got a really quick way to navigate directories in an xterm
Code:
  godir()  # Quick directory navigation using dmenu.
  {
    local dir 

    dir=${1:-$HOME}  
    dir="$(find "$dir" -type d -path "*/.*" -prune -o -type d -print 2>/dev/null \
           | dmenu -p "cd: " -l 20 )" && cd "$dir"
  }
  alias g=godir
Or, play a music album:
Code:
#!/bin/bash

music_dir="/srv/local/music"

play_selection()
{
   [ "$1" ] || return 1

   # Pre-load data files into vfs cache in order to
   # avoid constant disk I/O while playing. 
   
   ( cd "$1" && cat * >/dev/null )&

   # Play selected album

   exec ogg123 -d alsa -o dev:default -q "$1" 
}

cd "$music_dir" \
  && { [ "$DISPLAY" ] \
       && album="$( ls -d */* | dmenu -p "Select: " -l 15 )" \
       || album="$( ls -d */* | shuf -n 1 )" ; } \
  && play_selection "$album"
(that one relies on a .../Artist/Album/ structure)
I can usually find any album in my collection and play it with just a few key strokes. Add the script to another dmenu menu as a menu option, or bind it to a hot-key and it becomes seamless.

Or, how about a file selection/opening dialog:
Code:
file="$(find $HOME -name "*.doc" | dmenu -p "Open: " -l 20)" && xdg-open "$file"
just tune the find (or alternatively locate) for whichever file types/extensions you want to include. e.g. One for video files:
Code:
file="$(slocate -i -r '\(\.mp4\)\|\(\.mkv$\)\|\(\.avi$\)\|\(\.wmv\)' | dmenu -p 'Videos: ' -l 20 )"  &&  mplayer "$file"
If you're running a tiling WM like dwm or i3 that has a menu bar at the top or bottom of the screen that dmenu can overload its window upon then you end up with something completely seamless in most cases. And all done with a 41K window manager executable, a 21K dmenu executable, and a handful of simple scripts.

Last edited by GazL; 11-16-2014 at 07:46 AM. Reason: messed up the copy/paste of the godir example.
 
7 members found this post helpful.
Old 11-16-2014, 07:31 PM   #39
moisespedro
Senior Member
 
Registered: Nov 2013
Location: Brazil
Distribution: Slackware
Posts: 1,223

Original Poster
Rep: Reputation: 195Reputation: 195
Wow, I didn't know all of that was posible.

Thanks GazL.
 
Old 11-18-2014, 04:23 AM   #40
NoStressHQ
Member
 
Registered: Apr 2010
Location: Geneva - Switzerland ( Bordeaux - France / Montreal - QC - Canada)
Distribution: Slackware 14.2 - 32/64bit
Posts: 609

Rep: Reputation: 221Reputation: 221Reputation: 221
Quote:
Originally Posted by moisespedro View Post
Wow, I didn't know all of that was posible.

Thanks GazL.
Even Sky is NOT the limit !
 
Old 11-18-2014, 06:17 AM   #41
kevison
Member
 
Registered: Dec 2007
Location: Grand Rapids, Michigan USA
Distribution: Slackware/Bodhi/Manjaro
Posts: 149

Rep: Reputation: Disabled
Quote:
Originally Posted by kikinovak View Post
You do know that X should never ever be started as root?
Why? How many websites can you really hit with Lynx in a terminal when you are patching things and you need information? My system doesnt come up into X, but if I am on as root to upgrade kernal stuff or whatever... and I need information using lynx to hit the web is a horrible chore these days. when I am done I exit and pop over to my user account. I dont like running su so... why should i never ever use X as root?
 
Old 11-18-2014, 08:59 AM   #42
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by kevison View Post
Why? -snip- why should i never ever use X as root?
It's to protect both you and your computer. When you are running as root, there is nothing asking for elevated permissions, the permissions are just there and will be used whether or not you want them to be. If a program has a bug or vulnerability, it could easily wreak havoc on your system. This is the same reason that most people running Windows XP had so many issues with malware and the like, because UAC hadn't been introduced by Microsoft yet and the vulnerabilities of IE and the system let malware be installed with ease.

Running programs as root won't break anything (if nothing goes wrong), but it gives those programs unfettered access to the computer. If the program has a bug or is compromised, it could easily lead to your whole system being compromised, especially if an attacker is able to get a root shell because of a program.

It is easy enough to hit Ctrl+Alt+F6 to load up a new terminal, log in as a user, and then run startx. This protects both you and your computer.

See more here: http://askubuntu.com/questions/16178...-login-as-root
 
Old 11-18-2014, 11:37 AM   #43
kevison
Member
 
Registered: Dec 2007
Location: Grand Rapids, Michigan USA
Distribution: Slackware/Bodhi/Manjaro
Posts: 149

Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
It's to protect both you and your computer. When you are running as root, there is nothing asking for elevated permissions,.... This protects both you and your computer.

See more here: http://askubuntu.com/questions/16178...-login-as-root
Sorry I should have made it clear I was being somewhat rhetorical. I know exactly what permissions are had at both root and user level. I maintain a couple of servers so I am aware of whatever risk there could be if I wasn't diligent. As I mention I only use root when I need to do certain things... I was curious if there was something other than the usual permission and risk when running as an administrator. My home systems that my wife and I (and grandkids sometimes)use all run at the user level. Im not a proponent for doing everything everyday as root thats for sure. However I thought it a little crass to say NEVER EVER... there times when you have too. I have been admin to many servers in many companies as a software consultant over the years. I am extremely aware of what user I am logged in as. Thats why I commented that my root access I use XFCE when I need to and my user access uses enlightenment (E17/E18). This way I know who I am logged in as. So ... thanks for comment.

Last edited by kevison; 11-18-2014 at 11:46 AM.
 
Old 11-18-2014, 12:24 PM   #44
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by kevison View Post
Sorry I should have made it clear I was being somewhat rhetorical. I know exactly what permissions are had at both root and user level. I maintain a couple of servers so I am aware of whatever risk there could be if I wasn't diligent. As I mention I only use root when I need to do certain things... I was curious if there was something other than the usual permission and risk when running as an administrator. My home systems that my wife and I (and grandkids sometimes)use all run at the user level. Im not a proponent for doing everything everyday as root thats for sure. However I thought it a little crass to say NEVER EVER... there times when you have too. I have been admin to many servers in many companies as a software consultant over the years. I am extremely aware of what user I am logged in as. Thats why I commented that my root access I use XFCE when I need to and my user access uses enlightenment (E17/E18). This way I know who I am logged in as. So ... thanks for comment.
But there shouldn't ever be a need to run a WM/DE as root. There are ways to run individual programs as root if needed. But if you run the WM/DE as root, then everything in there runs as root, including any bugs or exploits that may be there from basically any application that is installed on the system. If you need an individual program to have root access, I know kdesu exists for kde, although, I don't know what the equivalent is in xfce (although, you could always set the $DISPLAY variable and then run it via escalated permissions in the terminal).

You may be aware of the risk, but it seems that the way to alleviate the risk is easy enough (and wouldn't happen often enough) that it is worth it to play it safe and run only what is needed under escalated permissions... especially with production servers in companies. If your personal computer is taken down because of something using root that shouldn't have, then it's a setback and your computer will be down for a bit. Not the end of the world. If you're talking a production server for a company, any downtime can be extremely bad and expensive. Why would you not want to play it safe whenever possible and mitagate those risks by only running what's needed as root?
 
Old 11-18-2014, 08:46 PM   #45
lems
Member
 
Registered: May 2004
Distribution: BSD
Posts: 269

Rep: Reputation: 119Reputation: 119
Quote:
Originally Posted by kevison View Post
[…] using lynx to hit the web is a horrible chore these days[…]
I have to disagree. It's actually my browser of choice, and especially wikis can be read with it quite nicely. It has numbered links and vi keys, as well as text-fields-need-activation, which most other text browsers lack. Of course, JavaScript is not supported, but most times I can get the pure text just fine; blogspot, wordpress, stackexchange or slackbuilds.org also render nicely. I haven't tested it with this forum, as most web-based forums are indeed rather hard to navigate with lynx, this is one of the rare occasions where I use a graphical browser (with scripts disabled, running as different user).
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Most reliable distro for desktop usage? tyko Linux - Newbie 24 12-15-2013 12:27 PM
processes/CPU Usage/Mem Usage desktop wallpaper ceantuco Linux - Newbie 2 04-13-2009 01:14 PM
how to determine cpu usage, memory usage, I/O usage by a particular user logged on li rags2k Programming 4 08-21-2004 04:45 AM
GDM faces and desktop -- trying to simplify sosiouxme Fedora 1 04-09-2004 08:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 02:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration