Error: Permission denied for xml = open(args.infile).read()

root@worker01:~/NetConf# netconf-client -u admin -p admin --host=10.146.11.237 --port=830 -i /home/parallel/clusterName.xml

Traceback (most recent call last): File “/snap/netconf-client/2/bin/netconf-client”, line 10, in sys.exit(main()) File “/snap/netconf-client/2/lib/python3.8/site-packages/netconf/main.py”, line 159, in main xml = open(args.infile).read() PermissionError: [Errno 13] Permission denied: ‘/home/parallel/clusterName.xml’ root@worker01:~/NetConf#

  1. File has required permission.
  2. Tried moving the file to /tmp, /root and accessing from there but the same result.

Can anyone please help here?

a snap (even when run as root) can not access other peoples home directories by default … if you are root, you can access /root, but not /home/parallel …

put your config into $SNAP_COMMON or $SNAP_DATA instead …