Page 2 of 3

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:25 am
by hsmith
peterooney wrote:Just as a matter of interest, is there any way to make Linux display the full current path at the command prompt, instead of just the current foldername?
You can issue the 'pwd' command to get your current path, but I am not 100% how to do it all the time. That would get super messy and take up half of your screen at all times though :/

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:26 am
by rkennedy
The directory you tried to compile in is the directory where the plugins are compiled. Not the source.

Thanks for that @eloyd. Yes, to check your current directory you can use the command pwd.

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:31 am
by neworderfac33
I can't use wget, as all downloads have to go via Security.
However, if my colleague comes back in tomorrow, hopefully we can use the Security-cleared nagios-plugins-2.0.tar tht's currently living on our Windows share, but I'll need my colleague's help to FTP it over.
I don't suppose you'd be interested in speculate as to how my plugins ended up in /usr/local/nagios/etc/libexec, would you..?

Cheers

Pete

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:33 am
by neworderfac33
"pwd" is a VERY useful tip - thank you! :-)

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:33 am
by eloyd
peterooney wrote:Just as a matter of interest, is there any way to make Linux display the full current path at the command prompt, instead of just the current foldername?
There is. Your prompt is what is showing you your current directory. You can change your prompt, assuming you're on a RHEL/CentOS machine running bash as your shell (which is the default) as follows:

Code: Select all

export PS1="\w $"
If you want to do this all the time, put it in your ~/.bashrc file. If you want more help, look at http://www.tldp.org/HOWTO/Bash-Prompt-H ... ences.html

EDIT: You can add any other characters in there as well to format it to look better.

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:34 am
by neworderfac33
And thank you for the tip about the source/compiled folders too - it makes a lot more sense now.

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:35 am
by eloyd
peterooney wrote:I don't suppose you'd be interested in speculate as to how my plugins ended up in /usr/local/nagios/etc/libexec, would you..?
This is the default location that Nagios expects to put the plugins into (and find them for execution). If they are not in this directory, you need to update the nagios.cfg file to say where they live.

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:36 am
by neworderfac33
AND the tips about the command prompt and /libexec

I'm having a good day today! :-)

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:40 am
by eloyd
Remember me when I start asking for MVP nominations next year. :-)

Re: Problem with check_http for https site

Posted: Tue Oct 20, 2015 10:45 am
by hsmith
eloyd wrote:Remember me when I start asking for MVP nominations next year. :-)
It would appear you're starting quite early this year :)