From 11:00 PM CDT Friday, May 10 – 02:30 PM CDT Saturday, May 11 (04:00 AM UTC – 07:30 PM UTC), ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI Linux Real-Time Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

System Exec VI Calling umount

Hi all,

I need to safe umount my FAT32 filesystem USB mass storage device, and my final customer should be able to do that from the VI Front Panel (running on cRIO-9030 with HMI enabled). I would like to run programmatically a command like:

sudo umount /dev/sdcX

but it is allowed only by admin (not by lvuser). How can I do that?

There is a way to create a bash script calling

su admin

passing directly the password, without prompting it? It seems that

su admin -p 'adminPassword'

doesn't work

Thank you in advance

Andrea

0 Kudos
Message 1 of 3
(3,237 Views)

su itself generally requires being run from a terminal (interactive), but of course you can install and configure sudo to work for any user on the system, including lvuser (the user that runs the LVRT runtime)

0 Kudos
Message 2 of 3
(2,880 Views)

You need to add your user to sudoers by Visudo command

CLA, CTA, CLED

0 Kudos
Message 3 of 3
(2,880 Views)