Which perl is being run? su - root will get you root's login shell along with root's default environment. sudo blah blah blah gets you your environment (notwithstanding any settings in your sudo configuration).
Try the difference between the env and which perl commands in both environments.
--MidLifeXis
In reply to Re: Script works when run with sudo, but not when run directly as root...?
by MidLifeXis
in thread Script works when run with sudo, but not when run directly as root...?
by bmalnad
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |