Hi Experts,
I am relatively new to GOLANG and trying a simple program as below which is
failing in fetching the output of a file, which works otherwise on the
command prompt:
Lang : GOLANG
OS : Linux/Centos
Problem : Using exec.command to get the output of a certain file
Error: Getting no such file or directory error:
command = fmt.Sprintf("cat /sys/bus/pci/devices/%s.0/numa_node",
name)
*2021/03/15 11:55:59 fork/exec cat
/sys/bus/pci/devices/0000:19:00.0/numa_node: no such file or directory*
*exit status 1*
However, the same executed on linux prompt works from the same working
directory as the code :
*[root-v05 ~]# cat /sys/bus/pci/devices/0000:19:00.0/numa_node*
*0*
[root-v05 ~]#
Please suggest what I may be missing.
Sharan
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/golang-nuts/c5f6d10b-e857-4652-ac94-0e200233db9dn%40googlegroups.com.