[Xorp-hackers] XORP beginner question: xorpsh has some connect problem

frank hu frank.1975.hu at gmail.com
Tue Dec 6 11:14:51 PST 2011


Thanks for the kind help!

It still has the same error even after I switched to use
"xorp_install.bash" script. My bad in my earlier email not clearly saying
the usage of "sudo" in "chmod" and "chown". I did run "chmod" and "chown"
as super user. otherwise, the command will just fail.
I tried to use xorp_install script and found that it has some extra info.
It tried to add the user "lanforge" to the group "xorp". I didn't see
that it was documented anywhere in xorp.net. So is it really necessary?  I
also saw the script tried to add the user "xorp" to the root group. Is that
necessary as well?

"
$ ps -ef|grep xorp
feng     15982     1  0 08:10 ?        00:00:01 gvim xorp_install.bash
root     16561     1  0 08:39 pts/0    00:00:00 xorp_fea
root     16564     1  0 08:39 ?        00:00:00
/usr/local/xorp/sbin/xorp_rtrmgr -d -P /var/run/xorp.pid -l /var/log/xorp
-b /etc/xorp/config.boot
feng     16566 21900  0 08:39 pts/0    00:00:00 grep --color=auto xorp
$ ls -l /var/tmp
total 0
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.AErxLy
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.f2DBgj
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.FFLIL3
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.iE6G21
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.JggugO
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.NZn6th
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.pS5ugj
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.vo6tL3
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.XE8zLy
srw-rw-r-- 1 root xorp 0 2011-12-06 08:39 xrl.Y7kGgO
$ sudo chmod 775 /var/tmp/xrl.*
$ sudo chown root:xorp /var/tmp/xrl.*
$ ls -l /var/tmp/
total 0
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.AErxLy
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.f2DBgj
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.FFLIL3
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.iE6G21
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.JggugO
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.NZn6th
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.pS5ugj
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.vo6tL3
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.XE8zLy
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 xrl.Y7kGgO
$ xorpsh -h
Usage: xorpsh [options]
Options:
  -c        Specify command(s) to execute
  -e        Exit immediately if cannot connect to the rtrmgr
  -h        Display this information
  -v        Print verbose information
  -t <dir>  Specify templates directory
Defaults:
  Templates directory        := /usr/local/xorp/share/xorp/templates
  Print verbose information  := false
$xorpsh
.... many errors...

[ 2011/12/06 08:44:04.691433  ERROR xorpsh:16580 XRL
libxipc/xrl_router.cc:478 lookup_sender ] Could not create XrlPFSender for
protocol = "unix" address = ":var:tmp:xrl.NZn6th"
[ 2011/12/06 08:44:04.691746  ERROR xorpsh:16580 LIBCOMM
libcomm/comm_user.c:886 comm_connect_unix ] Error connecting to unix
socket.  Path: /var/tmp/xrl.iE6G21.  Error: Permission deniedKilled
"

I checked the unix socket file /var/tmp/xrl.iE6G21.

"
$ ls -l /var/tmp/xrl.iE6G21
srwxrwxr-x 1 root xorp 0 2011-12-06 08:39 /var/tmp/xrl.iE6G21
$ cat /etc/group | grep xorp
root:x:0:xorp
xorp:x:1001:feng,root,xorp,lanforge
feng at feng-desktop:~$
"

Anyway, I figured out a possible way to get xorp to work.... Instead of
running xorpsh as a normal user "feng", I tried to run it as a normal user
"xorp" and then it gave me the CLI interfaces..

"
$ su xorp
Password:
$ pwd
/usr/local/xorp
$ ./sbin/xorpsh
Welcome to XORP on desktop
xorp at desktop> ?
Possible completions:
  configure            Switch to configuration mode
  exit                 Exit this command session
  help                 Provide help with commands
  ping                 Ping a hostname or IP address
  ping6                Ping an IPv6 hostname or IPv6 address
  quit                 Quit this command session
  show                 Display information about the system
  traceroute           Trace the IP route to a hostname or IP address
  traceroute6          Trace the IPv6 route to a hostname or IPv6 address
"

2011/12/6 Igor Maravić <igorm at etf.rs>

> Try
>
> sudo chmod -R 775 /var/tmp
> sudo chown -R  root:xorp /var/tmp
>
> BR
> Igor
>
> PS. The easier way to install Xorp would be with xorp_install script
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/xorp-hackers/attachments/20111206/08e5ae9b/attachment.html 


More information about the Xorp-hackers mailing list