grossmj wrote:
Hi,
Try to set the capture capability on Dynamips:
post19569.html#p19569Thanks for the idea. Here's what I did:
Code:
root /usr/bin # apt-get install libcap2-bin
libcap2-bin is already the newest version.
root /usr/bin # chmod 755 dynamips
root /usr/bin # chown root.root dynamips
root /usr/bin # setcap cap_net_raw,cap_net_admin+eip dynamips
root /usr/bin # getcap dynamips
dynamips = cap_net_admin,cap_net_raw+eip
The issue is that it did not work.
Any log files that dynamips writes will not be granted to write to the current directory (/usr/bin) which does not have write permissions for normal users. See also
http://forum.gns3.net/post7234.html#p7234.
So I added this:
Code:
cap_dac_override,cap_net_admin,cap_net_raw+eip
What cap_dac_override does is:
Bypass file read, write, and execute permission checks. (DAC is an abbreviation of "discretionary access control".)
Without write permissions I got theese error messages:
Quote:
Unable to create lock file "c7200_i0_lock".
VM default: unable to create instance!
c7200: unable to create instance default!
But I still receive the error.
Later edit:Found my error.
When adding interfaces to the cloud in Linux make sure not to add it like this:
nio_gen_eth lo100
in Linux subinterface indexes are separated by a colon (
:) between the name of the interface and it's index:
nio_gen_eth lo:100
The only settings I will keep is:
Code:
cap_dac_override,cap_net_admin,cap_net_raw+eip
That way, the dynamips binary has the proper permissions.
and just let the default file permissions as is:
Code:
root /usr/bin # stat dynamips
File: ‘dynamips’
Access: (0755/-rwxr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root)
After doing that I added two interfaces (one tap0 and one lo:101):

Then at the terminal I had to make then:
Note: For installing tap devices I used
this guide.
Code:
ifconfig tap0 10.100.100.100 netmask 255.255.255.0 up
ifconfig lo:101 10.100.100.101 netmask 255.255.255.0 up
Then I started the router and configured the e0/0 interface with the ip address 10.100.100.101, and after the no shut command.
Ping worked.