LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-31-2011, 03:43 AM   #1
madsovenielsen
Member
 
Registered: Aug 2009
Posts: 183

Rep: Reputation: 15
Setting up a Linux server with shell accounts. (Slackware 13)


Hello

How do i configure the system and user accounts so that the users can't access each others directories, delete system files, install packages etc. ?

I know i am probably going to need tools like chmod mkdir useradd

But i can't figure out how.

If you know a good tutorial, please point me in that direction.

/mads
 
Old 03-31-2011, 03:44 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
so they *can't* do this? That's just a default user... read the useradd manpage and add away. Or use whatever gui tools are provided on the system, assuming there are some.
 
1 members found this post helpful.
Old 03-31-2011, 03:48 AM   #3
madsovenielsen
Member
 
Registered: Aug 2009
Posts: 183

Original Poster
Rep: Reputation: 15
Okay.

How do i run scripts when a user log in ?

/mads
 
Old 04-13-2011, 11:58 AM   #4
Frakir
LQ Newbie
 
Registered: Apr 2011
Distribution: Slackware Linux 13.1, Slackware Linux 13.37, Debian 6
Posts: 2

Rep: Reputation: 0
If I were doing this, I'd create a file called /bin/userlogin:
Code:
script1
script2
bash
Then, run:
Code:
chown root:root /bin/userlogin
chmod 755 /bin/userlogin
to protect the file from modification

I'd then change the user's entry in /etc/passwd from:
Code:
frakir:x:5011:100:Frakir,,,:/home/frakir:/bin/bash
to
Code:
frakir:x:5011:100:Frakir,,,:/home/frakir:/bin/userlogin
Then, when that user would log in, the userlogin script would be run, dropping them to bash when it was finished.
Alternatively, you could add the script to the end of /etc/profile, but that applies to everyone, not just the users you want it to apply to.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Default Accounts of SUSE Linux Ent. Server v9 Bace Rock Linux - Newbie 0 12-01-2008 06:10 PM
Moving Linux accounts to MacOS X server? evilchild Linux - General 1 04-09-2005 08:05 PM
Setting up a linux server with Slackware Fantus Linux - Networking 4 08-27-2004 03:32 AM
Basic Linux Networking and setting up ssh/telnet/ftp user accounts... timmy_laf Linux - Newbie 2 01-05-2004 03:07 AM
setting up/ giving out shell accounts skeletal29 Linux - Security 2 08-25-2002 03:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 04:01 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