LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-19-2003, 05:19 AM   #1
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Rep: Reputation: 15
Unhappy vnc..telnet..rlogin..nothing works 4 me


namaste!

im a newbie in this networking area, and i sure am having my fill of problems...
well, i have two computers cross connected to form a LAN. iv got just one monitor, so *im trying to bring up the other PC`s terminal on this computer.*
the problem is that i can ping one from the other, but i cant do anything worthwhile...


one is running redhat 8.0 and the other 9.0.
the ip of the machine runnig the vnc server is 192.168.1.4 (it has no monitor)
the ip of this machine is 192.168.1.2 (has a monitor)
i tried to use "VNC for linux". i ran the vncserver on the machine which does not have a monitor .then i ran the command "vncviewer 192.168.1.4" on the other computer, but i got an error like "could not connect :bind: connection refused"

i tried "telnet 192.168.1.4"..i got the error "connection refused".

i tried "rsh" and "rlogin", and nothing happens..
where am i going wrong, and what is to be done? if u have some links where i can learn more about all this, kindly share them with me...

plz remember, *im tryting to manage two pcs with the same monitor, so id like something like vnc that brings up a grab of the other computer`s terminal*

PS. this vnc was working fine with a linux-windows combination!

thanx in advance!

PPS..having a torrid time twiddling the only monitor b\w the two pcs, so kindly help fast !

Last edited by funkymunky; 10-19-2003 at 05:22 AM.
 
Old 10-19-2003, 08:41 AM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
When connecting using vnc make sure you are using the display number this should have been given to you when you started the server - eg for display 1:
vncviewer 192.168.1.4:1

The reason you may not be able to conncet to the system via telnet is that telnet is now no longer installed by default - you need to use ssh instead (it is much more secure) - make sure the server is started:
service sshd restart

For all your problems you should also make sure you have no firewall rules in place:
iptables -L

If you are still having problems then post the output of hte iptables command and:
netstat -nlp
 
Old 10-19-2003, 09:21 AM   #3
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
nothing worked.... i had been using the correct display id all along..

hers the o/p out the iptables -L and the netstat -nlp commands



[root@mayank root]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination


[root@mayank root]# netstat -nlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 2213/smbd
tcp 0 0 0.0.0.0:6000 0.0.0.0:* LISTEN 1700/X
tcp 0 0 0.0.0.0:10000 0.0.0.0:* LISTEN 1647/perl
tcp 0 0 0.0.0.0:723 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 2553/sshd
tcp 0 0 0.0.0.0:7741 0.0.0.0:* LISTEN 1608/lisa
udp 0 0 192.168.1.2:137 0.0.0.0:* 2217/nmbd
udp 0 0 0.0.0.0:137 0.0.0.0:* 2217/nmbd
udp 0 0 192.168.1.2:138 0.0.0.0:* 2217/nmbd
udp 0 0 0.0.0.0:138 0.0.0.0:* 2217/nmbd
udp 0 0 0.0.0.0:10000 0.0.0.0:* 1647/perl
udp 0 0 0.0.0.0:7741 0.0.0.0:* 1608/lisa
raw 121760 0 0.0.0.0:1 0.0.0.0:* 7 1608/lisa
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node PID/Program name Path
unix 2 [ ACC ] STREAM LISTENING 1749 1558/gpm /dev/gpmctl
unix 2 [ ACC ] STREAM LISTENING 2529 1811/kdeinit: Runni /tmp/ksocket-root/kdeinit-:0
unix 2 [ ACC ] STREAM LISTENING 2048 1767/ssh-agent /tmp/ssh-XXlPI44T/agent.1709
unix 2 [ ACC ] STREAM LISTENING 2533 1814/kdeinit: dcops /tmp/.ICE-unix/dcop1814-1066569624
unix 2 [ ACC ] STREAM LISTENING 2684 1843/kdeinit: ksmse /tmp/.ICE-unix/1843
unix 2 [ ACC ] STREAM LISTENING 1787 1599/ /tmp/.font-unix/fs7100
unix 2 [ ACC ] STREAM LISTENING 2654 1829/artsd /tmp/mcop-root/mayank_home-0725-3f928fa0
unix 2 [ ACC ] STREAM LISTENING 2556 1817/kdeinit: klaun /tmp/ksocket-root/klauncherU0Yzyb.slave-socket
unix 2 [ ACC ] STREAM LISTENING 1958 1656/ /tmp/.gdm_socket
unix 2 [ ACC ] STREAM LISTENING 1968 1700/X /tmp/.X11-unix/X0
Active IPX sockets
Proto Recv-Q Send-Q Local Address Foreign Address State



what do i do next



thanx in advance
 
Old 10-19-2003, 09:37 AM   #4
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
Well there is no vnc server running by the looks of it - see what you get from:
ps -ef | grep Xvnc

ssh is running - can you connect to it:
ssh 192.168.1.2
 
Old 10-19-2003, 01:17 PM   #5
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
thanx for your time, dave..but i forgot to mention a few things

the iptables and netstat dumps are from the node 192.168.1.2, which is where im going to run the vncviewer from..

192.168.1.4, thats the one where the Xvnc server runs....hope yew arent mad at me

the o/p of the above commands was almost exactly the same as above....

"ssh 192.168.1.2" from the other node(192.168.1.4) says something like "connect at port 22:connection failed"
doesnt work





what next?
 
Old 10-19-2003, 01:24 PM   #6
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
No I'm not mad

Can you post the iptables and netstat commands from the machine with the vnc server on it. Just to see if the services are running etc.
 
Old 10-19-2003, 01:27 PM   #7
Guru3
Member
 
Registered: Sep 2003
Location: //home/sweden
Distribution: RedHat 9, Fedora Core 1
Posts: 360

Rep: Reputation: 31
lokkit

RedHat 8+9 have a deafault configuration tool for firewalls. If you type lokkit in console, it opens the configuration tool. Select no firewall to test. Once you establish that it does indeed work, you can user lokkit to allow ports 6001 and (I think) 5401 for your Xvnc.

The shadow knows...
 
Old 10-19-2003, 01:28 PM   #8
Guru3
Member
 
Registered: Sep 2003
Location: //home/sweden
Distribution: RedHat 9, Fedora Core 1
Posts: 360

Rep: Reputation: 31
I forgot this too: you have to use lokkit to enable ssh too.
 
Old 10-19-2003, 02:01 PM   #9
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
okay dave..and whoever else reads this..i ran the following commands in succession on the node 192.168.1.4, the one without the monitor.the only other node on the network is 192.168.1.2...


ot@compaq root]# ssh 192.168.1.2
ssh: connect to address 192.168.1.2 port 22: Connection refused
------------------------------------
[root@compaq root]# vncserver

New 'X' desktop is compaq.home:1

Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/compaq.home:1.log
-------------------------------------------
[root@compaq root]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
----------------------------------------------
[root@compaq root]# netstat -nlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:1024 0.0.0.0:* LISTEN 536/xinetd
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 583/smbd
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 482/
tcp 0 0 0.0.0.0:6000 0.0.0.0:* LISTEN 693/X
tcp 0 0 0.0.0.0:723 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 522/sshd
udp 0 0 192.168.1.4:137 0.0.0.0:* 587/nmbd
udp 0 0 0.0.0.0:137 0.0.0.0:* 587/nmbd
udp 0 0 192.168.1.4:138 0.0.0.0:* 587/nmbd
udp 0 0 0.0.0.0:138 0.0.0.0:* 587/nmbd
udp 0 0 0.0.0.0:111 0.0.0.0:* 482/
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node PID/Program name Path
unix 2 [ ACC ] STREAM LISTENING 1200 693/X /tmp/.X11-unix/X0
unix 2 [ ACC ] STREAM LISTENING 1228 719/ssh-agent /tmp/ssh-XX2Itcsk/agent.70
1
unix 2 [ ACC ] STREAM LISTENING 1037 574/ /tmp/.font-unix/fs7100
-----------------------------------------------------------------------------------
[root@compaq root]# ps -ex|grep Xvnc
814 pts/0 S 0:00 grep Xvnc SSH_AGENT_PID=719 HOSTNAME=compaq.home SHEL

-------------------------------------------------------------------------------


whenever i run "lokkit", the security setting is "high"..i changed it
to no-firewall, and even used the custom setting to enable orts, but when i choose "ok" and quit,and type "lokkit" again, i see nothing has changed! iv even tried a reboot....listening , Guru?

thanx in advance...
 
Old 10-19-2003, 02:13 PM   #10
Guru3
Member
 
Registered: Sep 2003
Location: //home/sweden
Distribution: RedHat 9, Fedora Core 1
Posts: 360

Rep: Reputation: 31
lokkit, again...

Ok, maybe "no firewall" isn't the best way to go. In lokkit, set security level to high. Then go into customize, make sure that DHCP and SSH are enabled. Don't worry if it's blank when you get there, just make sure when you quit lokkit that security level is high, and that in customize DHCP and SSH have little stars by them. In other ports enable poer 5900 and 6000 like this "5900:tcp 5901:tcp 6000:tcp 6001:tcp". I think that will work. Also is the one with no monitor running RH8 or 9?
 
Old 10-19-2003, 02:21 PM   #11
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
running redhat 8
 
Old 10-19-2003, 02:22 PM   #12
Guru3
Member
 
Registered: Sep 2003
Location: //home/sweden
Distribution: RedHat 9, Fedora Core 1
Posts: 360

Rep: Reputation: 31
The lokkit stuff I just posted should work under RH8.
 
Old 10-19-2003, 03:02 PM   #13
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
nope..that didnt work either...cant seem to get thru to any server from the other machine..."connection refused" with both vnc and ssh
:-(
 
Old 10-19-2003, 03:07 PM   #14
Guru3
Member
 
Registered: Sep 2003
Location: //home/sweden
Distribution: RedHat 9, Fedora Core 1
Posts: 360

Rep: Reputation: 31
OK, stupid question now, are these static IP or DHCP machines. Run ifconfig on each, make sure they have IP addresses... On the no monitor computer, try sshing to 127.0.0.1 (the loopback device) and see if that works. If it doesn't then SSH isn't running....
 
Old 10-19-2003, 03:52 PM   #15
funkymunky
Member
 
Registered: Jun 2003
Location: Austin, Texas
Distribution: Fedora Core 8, 32-bit
Posts: 126

Original Poster
Rep: Reputation: 15
both static ips.....i thnk were reaching a dead end
:-((
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Level & Checks block Services (Telnet, VNC...) kt8993 Mandriva 2 10-03-2004 09:35 PM
vnc over ssh works fine but then i have X problem... suhis Linux - General 1 08-17-2004 04:33 PM
rlogin & telnet differences Greg_courageous Linux - Software 1 04-27-2004 04:52 AM
rlogin, ftp, telnet sknoxy Linux - Newbie 10 09-22-2003 12:33 PM
vnc works on root but greyscreen for user Johnlester199 Linux - General 6 10-15-2002 06:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:59 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration