gns3-server icon indicating copy to clipboard operation
gns3-server copied to clipboard

Issues exporting project containing Docker containers

Open grossmj opened this issue 5 years ago • 3 comments
trafficstars

https://gns3.com/community/discussion/problem-duplicating-or-exporting

Could not export file /home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/dev/tty6: [Errno 13] Permission denied: '/home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/dev/tty6'

Could not export file /home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/dev/ttyS1: [Errno 13] Permission denied: '/home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/dev/ttyS1'

....

Could not export file /home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/proc/sys/vm/stat_refresh: [Errno 13] Permission denied: '/home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/proc/sys/vm/stat_refresh'

Could not export file /home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/proc/sys/vm/mmap_rnd_compat_bits: [Errno 13] Permission denied: '/home/gns3/GNS3/projects/37ac7fd1-fd10-4baf-8aea-317e086e2844/project-files/docker/7245294b-bbb9-4e6e-b2c9-7f90295029f6/proc/sys/vm/mmap_rnd_compat_bits'

grossmj avatar May 19 '20 03:05 grossmj

I cannot reproduce the problem.

grossmj avatar Jun 07 '20 02:06 grossmj

Oh, I can reproduce it. I just reproduced it 3 hours ago.

Now you have to understand that the way permissions work in Linux is foreign to native Windows users. Let me grab the full log:

(Okay, the heads up here is that I moved the entire contents of one directory (~/GNS3/projects/nat-cloud-combo) to another directory ( ~/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1 and I successfully moved the files,

But the .gns3 file showed up as me not being able to write to it. ( I wanted to change the name of the titlebar from nat-cloud-combo to dhcp-snooping-iosvl2-15.2.1 in the windows gui in the .gns3 file ) But I did know I did not have permission to write to the file when I began editing it in vim.

I have looked at the log again. It is 522 lines long and it is very confusing. I used the mv command to move the files from nat-cloud-combo to IOSvL2-15.2.1, but I broke the .gns3 file in IOSvL2-15.2.1 so I had to destroy the IOSvL2 directory and all it's directory.

I fixed it my problem. But I really do not understand what I did.

I am not deleting any lines in my logs - I just do not do that.

This is Ubuntu 18.04 and there is some thing about mv and cp that may, or may not, be affecting GNS3.

Again, no lines are deleted. Sorry.

x@y:~/GNS3/projects/nat-cloud-combo$ mv * /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1
x@y:~/GNS3/projects/nat-cloud-combo$ ls -al
total 8
drwxrwxr-x  2 x x 4096 Jul 21 02:49 .
drwxr-xr-x 12 x x 4096 Jul 21 02:38 ..
x@y:~/GNS3/projects/nat-cloud-combo$ pwd
/home/x/GNS3/projects/nat-cloud-combo
x@y:~/GNS3/projects/nat-cloud-combo$ cd /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ cp -r * /home/x/GNS3/projects/nat-cloud-combo
cp: cannot open 'project-files/docker/49f44a39-556f-492b-b7e2-3671912813af/var/log/btmp' for reading: Permission denied
cp: cannot open 'project-files/docker/49f44a39-556f-492b-b7e2-3671912813af/var/log/tallylog' for reading: Permission denied
cp: cannot access 'project-files/docker/49f44a39-556f-492b-b7e2-3671912813af/root': Permission denied
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ sudo chown -R x:x /home/x/GNS3/projects/personal/dhcp-snooping
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ cp -r * /home/x/GNS3/projects/nat-cloud-combo
cp: cannot create regular file '/home/x/GNS3/projects/nat-cloud-combo/project-files/docker/74ff2b66-386c-4284-b461-5971d4620d40/etc/apt/apt.conf.d/01autoremove-kernels': Permission denied
cp: cannot create regular file '/home/x/GNS3/projects/nat-cloud-combo/project-files/docker/f8d0d318-a12b-416d-8fe8-364ea93c6558/etc/apt/apt.conf.d/01autoremove-kernels': Permission denied
cp: cannot create regular file '/home/x/GNS3/projects/nat-cloud-combo/project-files/docker/c2cf43ed-76d5-4224-af74-8c99d7e79a66/etc/apt/apt.conf.d/01autoremove-kernels': Permission denied
cp: cannot create regular file '/home/x/GNS3/projects/nat-cloud-combo/project-files/docker/49f44a39-556f-492b-b7e2-3671912813af/etc/apt/apt.conf.d/01autoremove-kernels': Permission denied
cp: cannot create regular file '/home/x/GNS3/projects/nat-cloud-combo/project-files/docker/7db6c2d9-255d-4f6f-87c7-36b49545400e/etc/apt/apt.conf.d/01autoremove-kernels': Permission denied
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ cd /home/x/GNS3/projects/nat-cloud-combo/project-files/docker
x@y:~/.../nat-cloud-combo/project-files/docker$ ls -al
total 28
drwxr-xr-x 7 x x 4096 Jul 21 02:50 .
drwxr-xr-x 9 x x 4096 Jul 21 02:50 ..
drwxr-xr-x 6 x x 4096 Jul 21 02:50 49f44a39-556f-492b-b7e2-3671912813af
drwxr-xr-x 6 x x 4096 Jul 21 02:50 74ff2b66-386c-4284-b461-5971d4620d40
drwxr-xr-x 6 x x 4096 Jul 21 02:50 7db6c2d9-255d-4f6f-87c7-36b49545400e
drwxr-xr-x 6 x x 4096 Jul 21 02:50 c2cf43ed-76d5-4224-af74-8c99d7e79a66
drwxr-xr-x 6 x x 4096 Jul 21 02:50 f8d0d318-a12b-416d-8fe8-364ea93c6558
x@y:~/.../nat-cloud-combo/project-files/docker$ cd 49f44a39-556f-492b-b7e2-3671912813af
x@y:~/.../project-files/docker/49f44a39-556f-492b-b7e2-3671912813af$ ls -al
total 24
drwxr-xr-x  6 x x 4096 Jul 21 02:50 .
drwxr-xr-x  7 x x 4096 Jul 21 02:50 ..
drwxr-xr-x 47 x x 4096 Jul 21 02:51 etc
drwx------  2 x x 4096 Jul 21 02:51 root
drwxr-xr-x  2 x x 4096 Jul 21 02:50 tftpboot
drwxr-xr-x  4 x x 4096 Jul 21 02:50 var
x@y:~/.../project-files/docker/49f44a39-556f-492b-b7e2-3671912813af$ cd etc
x@y:~/.../docker/49f44a39-556f-492b-b7e2-3671912813af/etc$ ls -al
total 460
drwxr-xr-x 47 x x  4096 Jul 21 02:51 .
drwxr-xr-x  6 x x  4096 Jul 21 02:50 ..
-rw-r--r--  1 x x  3028 Jul 21 02:51 adduser.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:51 alternatives
drwxr-xr-x  6 x x  4096 Jul 21 02:50 apparmor.d
drwxr-xr-x  7 x x  4096 Jul 21 02:50 apt
-rw-r--r--  1 x x  2319 Jul 21 02:51 bash.bashrc
-rw-r--r--  1 x x   367 Jul 21 02:51 bindresvport.blacklist
drwxr-xr-x  2 x x  4096 Jul 21 02:50 cron.daily
-rw-r--r--  1 x x  2969 Jul 21 02:51 debconf.conf
-rw-r--r--  1 x x    11 Jul 21 02:51 debian_version
drwxr-xr-x  2 x x  4096 Jul 21 02:50 default
-rw-r--r--  1 x x   604 Jul 21 02:51 deluser.conf
drwxr-xr-x  3 x x  4096 Jul 21 02:50 dhcp
drwxr-xr-x  4 x x  4096 Jul 21 02:50 dpkg
-rw-r--r--  1 x x    96 Jul 21 02:51 environment
drwxr-xr-x  4 x x  4096 Jul 21 02:50 fonts
-rw-r--r--  1 x x    37 Jul 21 02:51 fstab
-rw-r--r--  1 x x   132 Jul 21 02:51 ftpusers
-rw-r--r--  1 x x  2584 Jul 21 02:51 gai.conf
-rw-r--r--  1 x x 18670 Jul 21 02:51 .gns3_perms
-rw-r--r--  1 x x   532 Jul 21 02:51 group
-rw-r--r--  1 x x   521 Jul 21 02:51 group-
-rw-r-----  1 x x   442 Jul 21 02:51 gshadow
-rw-r-----  1 x x   434 Jul 21 02:51 gshadow-
drwxr-xr-x  3 x x  4096 Jul 21 02:50 gss
-rw-r--r--  1 x x    92 Jul 21 02:51 host.conf
-rw-r--r--  1 x x    11 Jul 21 02:51 hostname
-rwxr-xr-x  1 x x   171 Jul 21 02:51 hosts
-rw-r--r--  1 x x   411 Jul 21 02:51 hosts.allow
-rw-r--r--  1 x x   711 Jul 21 02:51 hosts.deny
drwxr-xr-x  2 x x  4096 Jul 21 02:50 init
drwxr-xr-x  2 x x  4096 Jul 21 02:50 init.d
drwxr-xr-x  4 x x  4096 Jul 21 02:50 iproute2
-rw-r--r--  1 x x    26 Jul 21 02:51 issue
-rw-r--r--  1 x x    19 Jul 21 02:51 issue.net
drwxr-xr-x  3 x x  4096 Jul 21 02:50 kernel
drwxr-xr-x  2 x x  4096 Jul 21 02:50 ldap
-rw-r--r--  1 x x 17384 Jul 21 02:51 ld.so.cache
-rw-r--r--  1 x x    34 Jul 21 02:51 ld.so.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 ld.so.conf.d
-rw-r--r--  1 x x   267 Jul 21 02:51 legal
-rw-r--r--  1 x x   191 Jul 21 02:51 libaudit.conf
drwxr-xr-x  3 x x  4096 Jul 21 02:50 logcheck
-rw-r--r--  1 x x 10550 Jul 21 02:51 login.defs
drwxr-xr-x  2 x x  4096 Jul 21 02:50 logrotate.d
-rw-r--r--  1 x x   105 Jul 21 02:51 lsb-release
-rw-r--r--  1 x x     0 Jul 21 02:51 machine-id
-rw-r--r--  1 x x   812 Jul 21 02:51 mke2fs.conf
lrwxrwxrwx  1 x x    12 Jul 21 02:51 mtab -> /proc/mounts
drwxr-xr-x  3 x x  4096 Jul 21 02:51 mysql
-rw-r--r--  1 x x  9048 Jul 21 02:51 nanorc
drwxr-xr-x  6 x x  4096 Jul 21 02:50 network
-rw-r--r--  1 x x    91 Jul 21 02:51 networks
drwxr-xr-x  8 x x  4096 Jul 21 02:50 nginx
-rw-r--r--  1 x x   497 Jul 21 02:51 nsswitch.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 opt
lrwxrwxrwx  1 x x    21 Jul 21 02:51 os-release -> ../usr/lib/os-release
-rw-r--r--  1 x x   552 Jul 21 02:51 pam.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 pam.d
-rw-r--r--  1 x x  1188 Jul 21 02:51 passwd
-rw-r--r--  1 x x  1188 Jul 21 02:51 passwd-
drwxr-xr-x  4 x x  4096 Jul 21 02:50 perl
-rw-r--r--  1 x x   581 Jul 21 02:51 profile
drwxr-xr-x  2 x x  4096 Jul 21 02:50 profile.d
-rw-r--r--  1 x x  2932 Jul 21 02:51 protocols
-rw-------  1 x x     0 Jul 21 02:51 .pwd.lock
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc0.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc1.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc2.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc3.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc4.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc5.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rc6.d
drwxr-xr-x  2 x x  4096 Jul 21 02:51 rcS.d
-rwxr-xr-x  1 x x     0 Jul 21 02:51 resolv.conf
-rwxr-xr-x  1 x x   268 Jul 21 02:51 rmt
-rw-r--r--  1 x x   887 Jul 21 02:51 rpc
-rw-------  1 x x  1368 Jul 21 02:51 rsyslog.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 rsyslog.d
-rw-r--r--  1 x x  4141 Jul 21 02:51 securetty
drwxr-xr-x  4 x x  4096 Jul 21 02:50 security
drwxr-xr-x  2 x x  4096 Jul 21 02:50 selinux
-rw-r--r--  1 x x 10368 Jul 21 02:51 sensors3.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 sensors.d
-rw-r--r--  1 x x 19183 Jul 21 02:51 services
-rw-r-----  1 x x   737 Jul 21 02:51 shadow
-rw-r-----  1 x x   640 Jul 21 02:51 shadow-
-rw-r--r--  1 x x    73 Jul 21 02:51 shells
drwxr-xr-x  2 x x  4096 Jul 21 02:50 skel
drwxr-xr-x  2 x x  4096 Jul 21 02:50 snmp
drwxr-xr-x  2 x x  4096 Jul 21 02:50 ssh
-rw-r--r--  1 x x     0 Jul 21 02:51 subgid
-rw-r--r--  1 x x     0 Jul 21 02:51 subuid
-rw-r--r--  1 x x  2683 Jul 21 02:51 sysctl.conf
drwxr-xr-x  2 x x  4096 Jul 21 02:50 sysctl.d
drwxr-xr-x  3 x x  4096 Jul 21 02:50 systemd
drwxr-xr-x  2 x x  4096 Jul 21 02:50 terminfo
-rw-r--r--  1 x x  1260 Jul 21 02:51 ucf.conf
drwxr-xr-x  3 x x  4096 Jul 21 02:50 ufw
drwxr-xr-x  2 x x  4096 Jul 21 02:50 update-motd.d
drwxr-xr-x  2 x x  4096 Jul 21 02:50 vim
-rw-------  1 x x   127 Jul 21 02:51 vsftpd.conf
x@y:~/.../docker/49f44a39-556f-492b-b7e2-3671912813af/etc$ cd ..
x@y:~/.../project-files/docker/49f44a39-556f-492b-b7e2-3671912813af$ cd ..
x@y:~/.../nat-cloud-combo/project-files/docker$ cd ..
x@y:~/.../projects/nat-cloud-combo/project-files$ cd ..
x@y:~/GNS3/projects/nat-cloud-combo$ ls -al
total 1096
drwxrwxr-x  3 x x   4096 Jul 21 02:50  .
drwxr-xr-x 12 x x   4096 Jul 21 02:38  ..
-rw-r--r--  1 x x   5055 Jul 21 02:51  001-IOSv-IOSvL2.vim
-rw-r--r--  1 x x 140181 Jul 21 02:51  nat-cloud-combo.gns3
drwxr-xr-x  9 x x   4096 Jul 21 02:50  project-files
-rw-r--r--  1 x x 956174 Jul 21 02:51 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/GNS3/projects/nat-cloud-combo$ 
x@y:~/GNS3/projects/nat-cloud-combo$ /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1
bash: /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1: Is a directory
x@y:~/GNS3/projects/nat-cloud-combo$ cd /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1096
drwxr-xr-x 3 x x   4096 Jul 21 02:49  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ cp nat-cloud-combo.gns3 dhcp-snooping
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ mv dhcp-snooping dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1236
drwxr-xr-x 3 x x   4096 Jul 21 02:53  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-r--r-- 1 x x 140181 Jul 21 02:53  dhcp-snooping.gns3
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ chmod +w dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1236
drwxr-xr-x 3 x x   4096 Jul 21 02:53  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-r--r-- 1 x x 140181 Jul 21 02:53  dhcp-snooping.gns3
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ chmod u+w dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1236
drwxr-xr-x 3 x x   4096 Jul 21 02:53  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-r--r-- 1 x x 140181 Jul 21 02:53  dhcp-snooping.gns3
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ pwd
/home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ chmod g+x /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1/dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1236
drwxr-xr-x 3 x x   4096 Jul 21 02:53  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-r-xr-- 1 x x 140181 Jul 21 02:53  dhcp-snooping.gns3
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ chmod g-x /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1/dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ chmod g+w /home/x/GNS3/projects/personal/dhcp-snooping/IOSvL2-15.2.1/dhcp-snooping.gns3
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ ls -al
total 1236
drwxr-xr-x 3 x x   4096 Jul 21 02:53  .
drwxrwxr-x 3 x x   4096 Jul 21 02:48  ..
-rw-rw-r-- 1 x x   5055 Jul 19 20:08  001-IOSv-IOSvL2.vim
-rw-rw-r-- 1 x x 140181 Jul 21 02:53  dhcp-snooping.gns3
-rw-rw-r-- 1 x x 140181 Jul 21 02:35  nat-cloud-combo.gns3
drwxrwxr-x 9 x x   4096 Jul  9 05:19  project-files
-rw-rw-r-- 1 x x 956174 Jul 20 14:46 'Screenshot from 2020-07-20 14-46-41.png'
x@y:~/.../personal/dhcp-snooping/IOSvL2-15.2.1$ cd ~
x@y:~$ 

shrug I have everything working.

ghost avatar Jul 21 '20 07:07 ghost

Oh, the primary cause of the me dropping into terminal mode was that in GNS3 2.2.10 on my Ubuntu 18.04, which is run via the local server only enabled, that the "save project as" did not work. I do not know if I had the console working and my ubuntu machine does not log everything like my windows machine logs things that's in my to do bucket.

The GNS3 2.1.10 while fully working with this IOSvL2 project does not show as a "Recent Project" - now that is a totally different issue. But that issue has existed the last 5 restarts of GNS3. My IOSvL2 project is open right now and is active and the gns3_server.log - I am sure - is running merrily along at a debug level 0 - I will fix that debug level 0 before the sun goes down.

ghost avatar Jul 21 '20 07:07 ghost