Hi all. Has anyone developed a shell script to place a Media Agent into maintenance mode and stop services? I’m trying to cobble something together without hard coding credentials when running qlogin at the beginning of the script.
Are you concerned about the password because you want to create a script that multiple users can execute but you don’t want them to see the password? We can resolve this using sudo.
Create the scripts, chmod 700 the scripts, and config /etc/sudoers so users can run them.
Here’s an example I created of a script that runs “commvault status”. My user cannot access the script to see what’s inside, but my user can run the script. Does this address your concerns?
Are you concerned about the password because you want to create a script that multiple users can execute but you don’t want them to see the password? We can resolve this using sudo.
Create the scripts, chmod 700 the scripts, and config /etc/sudoers so users can run them.
Here’s an example I created of a script that runs “commvault status”. My user cannot access the script to see what’s inside, but my user can run the script. Does this address your concerns?
Are you concerned about the password because you want to create a script that multiple users can execute but you don’t want them to see the password? We can resolve this using sudo.
Create the scripts, chmod 700 the scripts, and config /etc/sudoers so users can run them.
Here’s an example I created of a script that runs “commvault status”. My user cannot access the script to see what’s inside, but my user can run the script. Does this address your concerns?
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.