Sponsored Content
Top Forums UNIX for Advanced & Expert Users Logging in and then su to root Post 16899 by killerserv on Friday 8th of March 2002 06:04:27 AM
Old 03-08-2002
First of all the su command can/must be used by previeleged users ie. root. Frequent change of password must be done to obtain maximum security between the server site and client side.

one way to do it is to add a script to either /etc/profile or the particular user's .profile that tests to restrict the user. Something like this in /etc/profile will work:

IAM=`who am i | cut -d" " -f1`
COUNT=`w | cut -d" " -f1 | grep "^$IAM$" | wc -l`
[ $COUNT -gt 1 ] && exit 0


Not sure whther that command works or not but one thing for suggestion. Do not disable the password. Changing the password will do (just an advise). In case of problem then your user might face some problem.
 

10 More Discussions You Might Find Interesting

1. SuSE

Logging in as root on SuSE 9.1

When I try to log on as root now all it does is load YaST. When I used to log on as root it would have a desktop and all...what has happened? Thanks in advance. (10 Replies)
Discussion started by: CTroxtell21
10 Replies

2. UNIX for Dummies Questions & Answers

Run non-root script as root with non-root environment

All, I want to run a non-root script as the root user with non-root environment variables with crontab. The non-root user would have environment variables for database access such as Oracle or Sybase. The root user does not have the Oracle or Sybase enviroment variables. I thought you could do... (2 Replies)
Discussion started by: bubba112557
2 Replies

3. UNIX for Advanced & Expert Users

What change in freeBSD OS to allow root logging using ssh?

Hi everybody, ] I would like to ask just simpe and short question. I am using freeBSD 6.0 and Debian Sarge. From Debian console I can log as root using ssh to bsd mashine but not vice versa. When I say in bsd console su I got sorry output, it does not allow me to su to root when I am logged... (5 Replies)
Discussion started by: 100days
5 Replies

4. AIX

Can't login root account due to can't find root shell

Hi, yesterday, I changed root's shell in /etc/passwd, cause a mistake then I can not log in root account (can't find correct shell). I attempted to log in single-mode, however, it prompted for single-mode's password then I type root's password but still can not log in. I'm using AIX 5L version 5.2... (2 Replies)
Discussion started by: neikel
2 Replies

5. Solaris

Prevent users logging in as root

I would like to know how to prevent users connecting to a server using SSH as root. I would still like them to be able to login with their username and then change to su. But I would like to prevent them logging in directly as root. I have searched the forum and read that I should set... (3 Replies)
Discussion started by: Sepia
3 Replies

6. HP-UX

problem in logging into root

when i am trying to login through root i am getting following error Last successful login for root: Tue Feb 3 16:44:40 IST-5:30 2009 on pts/tc Last unsuccessful login for root: Tue Feb 3 16:41:01 IST-5:30 2009 on pts/tc Please wait...checking for disk quotas crt0: ERROR couldn't open... (6 Replies)
Discussion started by: mnmca
6 Replies

7. Post Here to Contact Site Administrators and Moderators

Constant Logging In (After Logging Out)

Hi Everyone. First, I want to thank all of you for letting me participate in this great group. I am having a bit of a problem. After I get an email from a responder, I login to make my reply. In the mean time I get another response by email from another member, I go to reply to them and I... (6 Replies)
Discussion started by: Ccccc
6 Replies

8. UNIX for Dummies Questions & Answers

How to avoid logging with root user?

I have created a linux machine and installed some softwares on it with root user privileges . I used to login with root user credentials for doing the various task. Later i have realise that this is not the best practice to follow and there should be a new user with less privileges to be created... (1 Reply)
Discussion started by: pinga123
1 Replies

9. Solaris

Migration of system having UFS root FS with zones root to ZFS root FS

Hi All After downloading ZFS documentation from oracle site, I am able to successfully migrate UFS root FS without zones to ZFS root FS. But in case of UFS root file system with zones , I am successfully able to migrate global zone to zfs root file system but zone are still in UFS root file... (2 Replies)
Discussion started by: sb200
2 Replies

10. Linux

Syslog not logging successful logging while unlocking server's console

When unlocking a Linux server's console there's no event indicating successful logging Is there a way I can fix this ? I have the following in my rsyslog.conf auth.info /var/log/secure authpriv.info /var/log/secure (1 Reply)
Discussion started by: walterthered
1 Replies
PMDALMSENSORS(1)					      General Commands Manual						  PMDALMSENSORS(1)

NAME
pmdalmsensors - Linux hardware monitoring performance metrics domain agent (PMDA) SYNOPSIS
$PCP_PMDAS_DIR/lmsensors/pmdalmsensors [-d domain] [-l logfile] [-U username] DESCRIPTION
pmdalmsensors is a Performance Metrics Domain Agent (PMDA) which extracts performance metrics describing the state of hardware using the lm-sensors on compatible motherboards. The lmsensors PMDA exports metrics that measure fan speeds, core temperatures and voltage levels. A brief description of the pmdalmsensors command line options follows: -d It is absolutely crucial that the performance metrics domain number specified here is unique and consistent. That is, domain should be different for every PMDA on the one host, and the same domain number should be used for the same PMDA on all hosts. -l Location of the log file. By default, a log file named lmsensors.log is written in the current directory of pmcd(1) when pmdalmsen- sors is started, i.e. $PCP_LOG_DIR/pmcd . If the log file cannot be created or is not writable, output is written to the standard error instead. -U User account under which to run the agent. The default is the unprivileged "pcp" account in current versions of PCP, but in older versions the superuser account ("root") was used by default. INSTALLATION
If you want access to the names, help text and values for the lmsensors performance metrics, do the following as root: # cd $PCP_PMDAS_DIR/lmsensors # ./Install If you want to undo the installation, do the following as root: # cd $PCP_PMDAS_DIR/lmsensors # ./Remove pmdalmsensors is launched by pmcd(1) and should never be executed directly. The Install and Remove scripts notify pmcd(1) when the agent is installed or removed. FILES
$PCP_PMCDCONF_PATH command line options used to launch pmdalmsensors $PCP_PMDAS_DIR/lmsensors/help default help text file for the lmsensors metrics $PCP_PMDAS_DIR/lmsensors/Install installation script for the pmdalmsensors agent $PCP_PMDAS_DIR/lmsensors/Remove undo installation script for the pmdalmsensors agent $PCP_LOG_DIR/pmcd/lmsensors.log default log file for error messages and other information from pmdalmsensors PCP ENVIRONMENT
Environment variables with the prefix PCP_ are used to parameterize the file and directory names used by PCP. On each installation, the file /etc/pcp.conf contains the local values for these variables. The $PCP_CONF variable may be used to specify an alternative configura- tion file, as described in pcp.conf(5). SEE ALSO
PCPIntro(1), pmcd(1), pcp.conf(5) and pcp.env(5). Performance Co-Pilot PCP PMDALMSENSORS(1)
All times are GMT -4. The time now is 06:39 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy