ssingla Absent Member.
Absent Member.
357 views

How to get the .profile executed for a user id when running a shell script on a unix server ?

While running a script on a Unix server using a ssh protocol, the tool is not executing the .profile of that user and hence not setting up proper environment for the script to be successful. Can u please suggest something so that the user's .profile is executed prior to running the script ?

 

Thanks

Labels (1)
Tags (1)
0 Likes
1 Reply
Absent Member.. ntt00015 Absent Member..
Absent Member..

Re: How to get the .profile executed for a user id when running a shell script on a unix server ?

Hi,
If you use SSH shell operation you can set profile settings with first command after logon and then you can run your script. If you use SSH command operation, you can use the sessionId output parameter for the next command operation.


Best Regards.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.