[phpBB Debug] PHP Notice: in file /includes/db/dbal.php on line 110: Undefined array key "cached"
[phpBB Debug] PHP Notice: in file /includes/db/dbal.php on line 111: Undefined array key "normal"
[phpBB Debug] PHP Notice: in file /includes/db/dbal.php on line 112: Undefined array key "total"
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3391: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3393: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3394: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3395: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2922)
Cabrillo College Linux Classes • View topic - Lab- Legolas shell

Lab- Legolas shell

UNIX/Linux System Administration

Lab- Legolas shell

Postby Tim Childers on Wed Oct 29, 2008 11:32 am

In the lab should Legolas shell to be just tcsh or /bin/tsch?
Tim Childers
 
Posts: 57
Joined: Mon Oct 06, 2008 6:33 pm

Re: Lab- Legolas shell

Postby fred deakin on Wed Oct 29, 2008 2:01 pm

Hi Tim,

You don't need to put the absolute path. Just "tcsh" works. I haven't tried it, but I'm guessing that if you use the absolute path, the kernel won't be able to find the shell.

Fred
fred deakin
 
Posts: 23
Joined: Tue Sep 02, 2008 7:11 pm

Re: Lab- Legolas shell

Postby Jonathan Simms on Sun Nov 02, 2008 11:07 pm

Fred and Tim,

Fred, I don't want to contradict you however I believe it would be best practice to use an absolute path to the shell in this case. Using useradd in the lab I found that when adding a shell, using flag -s, that if you don't supply the absolute path useradd will not recognize the shell. Personally I would go with the absolute path name to avoid ambiguity.

Jonathan.
Jonathan Simms
 
Posts: 119
Joined: Tue Sep 02, 2008 7:11 pm

Re: Lab- Legolas shell

Postby keivn dodd on Mon Nov 03, 2008 2:04 pm

Without using absolute path tsch does not necessarily point to /bin/tcsh but rather could point to anything named tsch in a $path variable directory.
keivn dodd
 
Posts: 43
Joined: Sat Sep 13, 2008 2:30 am

Re: Lab- Legolas shell

Postby Tim Childers on Mon Nov 03, 2008 5:07 pm

The reason whay pointed this out was because the lab was miss-leading, it just said "tsh". You need the absoute path, because when you login one first thing it dose is fine the shell you are using. Is there is no absolute path and it will try to fine tsh in /.
Tim Childers
 
Posts: 57
Joined: Mon Oct 06, 2008 6:33 pm

Re: Lab- Legolas shell

Postby fred deakin on Mon Nov 03, 2008 5:28 pm

I edited the /etc/passwd file to point to tcsh. I didn't use the absolute path because (I assume) the /etc/passwd file points to the /bin directory.
fred deakin
 
Posts: 23
Joined: Tue Sep 02, 2008 7:11 pm

Re: Lab- Legolas shell

Postby Jonathan Simms on Mon Nov 03, 2008 10:08 pm

Fred,

I don't believe that /etc/passwd looks into the bin directory unless specified to do so. In fact I don't think a shell is even necessary for certain account types such as accounts that are non-interactive and non-login. If you take a look at the /etc/passwd file for opus you will notice that there are some accounts which are not shells, such as scp. I think that using an absolute path is good practice and if it is necessary for /etc/passwd that I'm not sure of however as Kevin noted that by used an absolute path you are going to be certain which tcsh you're using which avoids a security issue in the off chance that you might have tcsh file somewhere other than /bin and you have set, or someone else has set, your home directory at the beginning of PATH.
Jonathan Simms
 
Posts: 119
Joined: Tue Sep 02, 2008 7:11 pm


Return to CIS 191B - Fall 2008

Who is online

Users browsing this forum: No registered users and 0 guests

cron