1 |
On Thu, Mar 19, 2009 at 11:10 AM, Joseph <syscon780@×××××.com> wrote: |
2 |
> On 03/19/09 10:51, Paul Hartman wrote: |
3 |
>>> |
4 |
>>> Yes, I tried it already: |
5 |
>>> |
6 |
>>> passwd -u nx |
7 |
>>> passwd: unlocking the user would result in a passwordless account. |
8 |
>>> You should set password with usermod -p to unlock this user account. |
9 |
>>> Password changed. |
10 |
>>> |
11 |
>>> What do you do next? |
12 |
>>> |
13 |
>>> When I try to run again: |
14 |
>>> nxsetup --install --setup-nomachine-key --clean --purge |
15 |
>>> |
16 |
>>> I get: |
17 |
>>> ... |
18 |
>>> Setting up /var/log/nxserver.log ...done |
19 |
>>> Setting up special user "nx" ...passwd: unlocking the user would result |
20 |
>>> in a |
21 |
>>> passwordless account. |
22 |
>>> You should set a password with usermod -p to unlock this user account. |
23 |
>>> Password changed. |
24 |
>>> done. |
25 |
>>> ... |
26 |
>>> ----> Testing your nxserver connection ... |
27 |
>>> Permission denied (publickey,keyboard-interactive). |
28 |
>>> Fatal error: Could not connect to NX Server. |
29 |
>>> |
30 |
>>> Please check your ssh setup: |
31 |
>>> |
32 |
>>> The following are _examples_ of what you might need to check. |
33 |
>>> |
34 |
>>> - Make sure "nx" is one of the AllowUsers in sshd_config. |
35 |
>>> (or that the line is outcommented/not there) |
36 |
>>> - Make sure "nx" is one of the AllowGroups in sshd_config. |
37 |
>>> (or that the line is outcommented/not there) |
38 |
>>> - Make sure your sshd allows public key authentication. |
39 |
>>> - Make sure your sshd is really running on port 22. |
40 |
>>> - Make sure your sshd_config AuthorizedKeysFile in sshd_config is |
41 |
>>> set |
42 |
>>> to authorized_keys2. |
43 |
>>> (this should be a filename not a pathname+filename) |
44 |
>>> - Make sure you allow ssh on localhost, this could come from some |
45 |
>>> restriction of: |
46 |
>>> -the tcp wrapper. Then add in /etc/hosts.allow: ALL:localhost |
47 |
>>> -the iptables. add to it: |
48 |
>>> $ iptables -A INPUT -i lo -j ACCEPT |
49 |
>>> $ iptables -A OUTPUT -o lo -j ACCEPT |
50 |
>>> |
51 |
>>> |
52 |
>>> So at this point I'm back to square one in log/messages I get: |
53 |
>>> User nx not allowed because account is locked |
54 |
>> |
55 |
>> Oh, try to give user nx a password on your system. It uses ssh keys |
56 |
>> to login, so it doesn't even matter what the password is. Just don't |
57 |
>> make it something easily guessed/brute-force like "nx" or "1234" or |
58 |
>> else you might have some unwanted guests in your system :) |
59 |
> |
60 |
> I did give it a password usermod -p something nx |
61 |
> |
62 |
> it accepted the password, now do I run the setup again: |
63 |
> nxsetup --install --setup-nomachine-key --clean --purge |
64 |
> |
65 |
> If I try to login from another machine do I login as user "nx"? |
66 |
> When I try to login from another machine on my network I get: |
67 |
> Your guest account has expired... |
68 |
|
69 |
The way NX works is it uses the nx user as an intermediate. You need |
70 |
to login as a normal user, and you need to explicitly give that user |
71 |
permission to use NX by doing nxserver --useradd yourname (which will |
72 |
generate NX ssh keys and put them in that user's directory). |
73 |
|
74 |
If you use interactive/PAM authentication on your system, NX can use |
75 |
your user's normal system password; if you use key-based |
76 |
authentication for SSH the only way to make NX work is to use its |
77 |
internal password database and assing an NX-specific password to that |
78 |
user. In nxclient, copy the normal SSH key, and then in the nxclient |
79 |
login box put the NX username and password. |