?
Solved

How to enable Login as Root via NX?

Posted on 2007-12-04
9
Medium Priority
?
14,882 Views
Last Modified: 2013-12-16
I have a RHEL 4.6 rack mount server running NX Server 3. I am using this for some testing purposes, but I don't want to sit in the server room. I'd like to sit at my desk and remotely work on the server.

I have installed the free version of NX Server (with Client and Node)  from NoMachine. I can make a connection as a non-root user, but I cannot do this as root. (I know - this is a very big security hole, and I can sudo or su once I've made the connectionas a non-root user etc. - but I am doing this for some temporary testing and simply don't want to sit in the server room at the console to do this, and I don't want to enter the root password every time I launch something in the GUI.)

I can ssh to the server as root, but when I try to log in as root via the NX client, I get the message: "User root' cannot be used as an NX user."

My installation of  NX Server had no customizations - just the generic default install other than generating new DSA keys.

How can I enable logging in as root via the NX Client?
0
Comment
Question by:shofarslee
8 Comments
 
LVL 13

Expert Comment

by:WizRd-Linux
ID: 20417658
check /etc/ssh/sshd_config and check the setting PermitRootLogins, if it is set to no or undefined it will deny root logins.

I haven't personally used NX before, but it may be a restriction in the client??
0
 

Author Comment

by:shofarslee
ID: 20420085
I believe the problem is with the NX Server configuration, not with ssh or with the NX client.

Here's why:

1) I can make an ssh connection to the server as root. (PermitRootLogins is already set to "yes", by the way.)

2) Using the same NX Client, I can make a connection to another server, logging in as root. That other server is running NX Server version 2. The server on which I want to log in as root is running NX Server version 3.

Unless someone knows for sure that logging in as root is absolutely disabled in version 3 of NX Server, I'm hoping there must be some simple configuration change to enable this.

Thanks



0
 

Expert Comment

by:pillaisuder
ID: 20427583
1.check /etc/ssh/sshd_config  fileand check the parameter
PermitRootLogins if it is set to no or not specified set as yes
2.edit /etc/pam.d/remote
and diable the line       account    required     pam_nologin.so
and try to telnet as root from another machine
and tell me the result
0
A Cyber Security RX to Protect Your Organization

Join us on December 13th for a webinar to learn how medical providers can defend against malware with a cyber security "Rx" that supports a healthy technology adoption plan for every healthcare organization.

 

Author Comment

by:shofarslee
ID: 20429591
The /etc/ssh/sshd_config file of the remote server (Let's refer to this server as "RemoteServer1") has the following line:
PermitRootLogin Yes

(In other words, PermitRootLogin is explicitly enabled for ssh.)

At a terminal command prompt on my local workstation, I can successfully log in as root to "RemoteServer1" using ssh (using: ssh root@RemoteServer1). NX uses ssh tunnelling for authentication and link parameter negotiation.

There was no "account      required      pam_nologin.so" line in the /etc/pam.d/remote file. There was an "account     required     pam_stack.so service=system-auth" line, but not knowing what this does, I didn't want to delete it.

Other info:
1) Using the NX Client on my local system, I can log in as root and open up an NX session to a different server. (Let's call this one "OldRemoteServer2".)

2) Using the same NX Client, I cannot log in as root to "RemoteServer1" via NX.

3) NX uses ssh. Since #1 shows that the NX Client is capable of making a connection as root (to "OldRemoteServer2"), I assume the reason for #2 is a configuration problem with NX Server on "RemoteServer1"
0
 

Accepted Solution

by:
shofarslee earned 0 total points
ID: 20485285
I heard from NX that this feature is totally disabled in their current version of the product, but they will look into adding this feature back in the future.
0
 
LVL 13

Expert Comment

by:WizRd-Linux
ID: 20488060
In this instance I agree with the refund as it is not possible to resolve the issue.
0
 
LVL 1

Expert Comment

by:modus_operandi
ID: 20513046
Closed, 500 points refunded.
modus_operandi
EE Moderator
0
 
LVL 2

Expert Comment

by:peterlambrechtsen
ID: 21595222
I have found a work-around to this issue.

On Suse Linux Server if you configure your desktop to be "Unix" and the Display Manager to be "XDM" instead of Gnome or KDE, then when you connect to your NX server using a valid username & password (that isn't root) you are presented with a regular login screen that you CAN login with your root username and password.

You can then leave this session up, and disconnect from it etc.
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to security, there are always trade-offs between security and convenience/ease of administration. This article examines some of the main pros and cons of using key authentication vs password authentication for hosting an SFTP server.
I have written articles previously comparing SARDU and YUMI.  I also included a couple of lines about Easy2boot (easy2boot.com).  I have now been using, and enjoying easy2boot as my sole multiboot utility for some years and realize that it deserves …
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Suggested Courses
Course of the Month16 days, left to enroll

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question