Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

is there any way to print or read PIG_HOME through terminal

avatar
Expert Contributor

I would like to print or read pig_home from terminal.Is there any way???

1 ACCEPTED SOLUTION

avatar
Master Guru

I assume you are using HDP? In that case PIG_HOME is set when executing the pig command. If you cat /usr/bin/pig you can find the line export PIG_HOME=${PIG_HOME:-/usr/hdp/2.3.2.0-2950/pig}. So you could run this manually.

View solution in original post

2 REPLIES 2

avatar
Master Guru

I assume you are using HDP? In that case PIG_HOME is set when executing the pig command. If you cat /usr/bin/pig you can find the line export PIG_HOME=${PIG_HOME:-/usr/hdp/2.3.2.0-2950/pig}. So you could run this manually.

avatar
Expert Contributor

@Benjamin Leonhardi

Thank you.Yeah,The script setting the environmental variable and then executing pig script in $PIG_HOME like

exec /usr/hdp/2.2.8.0-3150/pig/bin/pig.distro "$@"