Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

getusershell(3) [redhat man page]

GETUSERSHELL(3) 					     Linux Programmer's Manual						   GETUSERSHELL(3)

NAME
getusershell, setusershell, endusershell - get legal user shells SYNOPSIS
#include <unistd.h> char *getusershell(void); void setusershell(void); void endusershell(void); DESCRIPTION
The getusershell() function returns the next line from the file /etc/shells, opening the file if necessary. The line should contain the pathname of a valid user shell. If /etc/shells does not exist or is unreadable, getusershell() behaves as if /bin/sh and /bin/csh were listed in the file. The setusershell() function rewinds /etc/shells. The endusershell() function closes /etc/shells. RETURN VALUE
The getusershell() function returns a NULL pointer on end-of-file. FILES
/etc/shells CONFORMING TO
BSD 4.3 SEE ALSO
shells(5) BSD
1993-07-04 GETUSERSHELL(3)

Check Out this Related Man Page

GETUSERSHELL(3) 					     Linux Programmer's Manual						   GETUSERSHELL(3)

NAME
getusershell, setusershell, endusershell - get permitted user shells SYNOPSIS
#include <unistd.h> char *getusershell(void); void setusershell(void); void endusershell(void); Feature Test Macro Requirements for glibc (see feature_test_macros(7)): getusershell(), setusershell(), endusershell(): _BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500) DESCRIPTION
The getusershell() function returns the next line from the file /etc/shells, opening the file if necessary. The line should contain the pathname of a valid user shell. If /etc/shells does not exist or is unreadable, getusershell() behaves as if /bin/sh and /bin/csh were listed in the file. The setusershell() function rewinds /etc/shells. The endusershell() function closes /etc/shells. RETURN VALUE
The getusershell() function returns a NULL pointer on end-of-file. FILES
/etc/shells ATTRIBUTES
Multithreading (see pthreads(7)) The getusershell(), setusershell() and endusershell() functions are not thread-safe. CONFORMING TO
4.3BSD. SEE ALSO
shells(5) COLOPHON
This page is part of release 3.53 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/. GNU
2013-06-21 GETUSERSHELL(3)
Man Page

7 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

ftp questions

Hi, Im trying to setup a anonymous FTP server. I am using Solaris 9 and I am trying to use the ftpconfig command. According to the man page on this command it will copy and set up all the components needed to operate an anonymous ftp server, including creating the ftp user accounts, etc... (5 Replies)
Discussion started by: lewisoco
5 Replies

2. Shell Programming and Scripting

korn shell question

Hi all, I am trying to tweak my ksh , i am running V: Version M-11/16/88i I have my Backspace and up/down arrows working using the following code in my ~/.profile file. set -o emacs alias __A=$(print '\020' ) alias __B=$(print '\016' ) alias __C=$(print '\006' ) alias __D=$(print... (4 Replies)
Discussion started by: mich_elle
4 Replies

3. Shell Programming and Scripting

ksh script as a login shell return "no controlling terminal"

I have created a ksh shell script and used it as a login shell for a user. </etc/passwd> lramirev:x:111:200:Luis:/export/home/menush:/usr/local/menush/menush My shell script is like this: </usr/local/menush/menush> #!/bin/ksh # if ] then . $HOME/.profile fi ... (8 Replies)
Discussion started by: lramirev
8 Replies

4. Solaris

Ftp access denied

Hello,I must share file from Linux machine to Solaris.I've enabled ftp with svcadm enable ftp,when I connect from Linux box I have this "Name (192.168.1.4:root): anonymous 331 Guest login ok,send your complete e-mail address as password Password : (I give my e-mail address) 530 Login incorrect... (3 Replies)
Discussion started by: bgf0
3 Replies

5. Solaris

Enable FTP for root user in Solaris 10

I am not able to get ftp working for Solaris 10 for root user. I am getting login failed error. 331 Password required for root. Password: 530 Login incorrect. Login failed. Tried following things already. 1. SFTP works ok, still would like to know why FTP is not working (curious). 2.... (5 Replies)
Discussion started by: webkid
5 Replies

6. UNIX for Dummies Questions & Answers

The /etc/shells file is missing.

Hi the /etc/shells file is missing on some of development boxes. Is this ok? Where can I find this file? ---------- Post updated at 07:07 AM ---------- Previous update was at 07:07 AM ---------- I have solaris, linux, aix and hpux machines and on all of these machines the /etc/shells file is... (8 Replies)
Discussion started by: manju--
8 Replies

7. UNIX for Dummies Questions & Answers

default shell for the user

for example, if we specify,#!/usr/bin/ksh then the script will be executed in korn shell. If we don't specify that line, the script will be executed using the default shell. So, how we can identify the default shell for the current user? Will it be in .profile file ? Thanks (13 Replies)
Discussion started by: pandeesh
13 Replies