Re: differences between service command and running command directly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi again,

Very very strange.

The service command executes:

env -i LANG=es_ES.UTF-8 PATH=/sbin:/usr/sbin:/bin:/usr/bin TERM=xterm
/etc/init.d/httpd status

If I run this command from the shell, it runs ok, but If I don´t
give LANG=es_ES.UTF-8 I get the error.

I´m going to continue investigating...

Greetings,

ESG

2011/10/4 ESGLinux <esggrupos@xxxxxxxxx>

> Hi Barry,
>
> very good your idea, !!!
>
> The output are very very very different,
>
> I´m going to analize it, and I´ll publish the results....
>
> Thanks,
>
> ESG
>
>
>
> 2011/10/4 Barry Brimer <lists@xxxxxxxxxx>
>
>>  I use service and running the command in /etc/init.d/ directly  to run
>>> the
>>> services in that directory. Until now I thought it was the same to run,
>>> for
>>> example:
>>>
>>> service httpd status
>>>
>>> and
>>>
>>> /etc/init.d/httpd status
>>>
>>> but now I have a server that they don´t do the same:
>>>
>>
>> <snip>
>>
>>
>>  Anyone can explain me this? I suposse it´s something about enviroment
>>> variables, but I can´t see the difference
>>>
>>
>> I would run both with bash -x and redirect the output and compare or diff
>> them.
>>
>> bash -x service httpd status >/tmp/service.log 2>&1
>>
>> bash -x /etc/init.d/httpd status >/tmp/initscript.log 2>&1
>>
>> Barry
>> --
>> redhat-list mailing list
>> unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
>> https://www.redhat.com/mailman/listinfo/redhat-list
>>
>
>
-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list



[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux