LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   SSH... don't mind me. (https://www.linuxquestions.org/questions/linux-newbie-8/ssh-dont-mind-me-938973/)

thezerodragon 04-09-2012 06:16 PM

SSH... don't mind me.
 
Hello LQ,

I haven't been here since Fedora 16 was released because I basically haven't had a single problem with it.

My main computer runs it fine, despite several hardware changes, and so I built a second system out of spare parts in the living room. I installed my old Fedora 15 disc and successfully ran preupgrade so now both machines run fc16-x86_64.

But it's inconvenient to have to walk out into the living room and plug a monitoring into the second machine. What's an elegant and lightweight way for me to access this second machine from the main one? I am not familiar with setting up networks on Linux. Both devices are hardwired to the same ADSL router/modem and are on its MAC whitelist.

Can I just use SSH to do this? Can I do it by IP directly so I could potentially access truly remote systems in the future? Ideal for me is a command line solution that allows me to switch to GUI if necessary, but by default displays the remote system's CLI.

thezerodragon 04-09-2012 06:24 PM

also...
 
I realize a complete answer to this kind of question involves research on the part of the asker. I'm just looking for some pointers in the right direction. Thanks,

TobiSGD 04-09-2012 06:44 PM

For CLI access SSh is infact the best option. You can even run GUI applications through a SSH channel. Other options for GUI access would be VNC and FreeNX.

Janus_Hyperion 04-09-2012 06:45 PM

There are a few options that are available.

ssh -X
vncserver/vncviewer
rdesktop
x11vnc

See which of these would best fit your needs.

thezerodragon 04-09-2012 06:52 PM

Great, thanks for your input.

What's a good tutorial for getting started with SSH? Does it come installed by default? Are the man and info coreutils invocation detailed enough for a layperson?

Thanks again.

suicidaleggroll 04-09-2012 07:57 PM

It should be ready to go already, I'm pretty sure fedora has the ssh server installed and running by default.

Try running
Code:

ssh -Y user@ip
Swapping user with your username and ip with the remote machine's local IP, and see what happens

thezerodragon 04-09-2012 10:24 PM

all done
 
It wasn't quite that simple.

At first I got an error of "no path to host"

Checked the router's settings- all good

Then I got an error message of:
"connection refused"

turns out that sshd has to be restarted on both machines

then the connection was established, but
"read from socket failed: connection reset by peer"

this was solved by the command
Code:

ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key
issued as root from /etc/ssh/ to regenerate valid keys

since then I've been able to connect. Thanks again.

thezerodragon 04-10-2012 09:22 AM

one more thing
 
I can't ssh back in after I tell the remote machine to reboot. I have to go back over to it and restart sshd. Is there a way to have it automatically restart when the computer reboots.

On another note, (I'll start a new thread if necessary) how do I fix the yum repos? I found out the old computer was still using fc.15 and it keeps trying a bunch of non-working mirrors whenever I try to update anything.

dougt 04-10-2012 10:19 AM

You need to add the sshd service to the default run level for your system. Have a look at "chkconfig" and /etc/inittab

Janus_Hyperion 04-10-2012 10:33 AM

Since you are running Fedora 16,

Code:

systemctl enable sshd.service
This should start ssh service everytime you start the computer.

chrism01 04-11-2012 09:19 PM

Note that Fedora comes out with new versions about every 13 mths(?); you may want to look at Centos (free version of RHEL) as it is supported/updated for a very long time.
https://access.redhat.com/support/po...pdates/errata/


All times are GMT -5. The time now is 07:40 PM.