can't run perl commands from command line

Discussion in 'Perl Misc' started by josephweiss@SPAMMOgmail.com, Jul 28, 2005.

  1. Guest

    Greetings, I just installed perl v5.8.7 onto a 2003 server box. I can
    only seem to get perl -v to run on the command line only when I cd into
    the c:\perl\bin directory.

    >From the commad line at any other location I am getting the ... 'is not

    recognised as an internal or external command, operable program or
    batch file error'.

    I am plannign on running MRTG on this box and I am sort of new to perl.
    I got mrtg to run on one of my workstations with win2k but I am
    stumbling with this 2003 server.

    Is it an IIS issue? Is it a permissions issue?

    Thanks all!
     
    , Jul 28, 2005
    #1
    1. Advertising

  2. i'm not familiar with running Perl on a Windows box, but it sounds like
    you need to set your PATH Environment variable to include the absolute
    path to the location of your Perl.
     
    it_says_BALLS_on_your forehead, Jul 28, 2005
    #2
    1. Advertising

  3. On 28 Jul 2005 06:12:59 -0700
    "it_says_BALLS_on_your forehead" <> wrote:

    > i'm not familiar with running Perl on a Windows box, but it sounds like
    > you need to set your PATH Environment variable to include the absolute
    > path to the location of your Perl.


    I've only used Win98, I think you can set your path in a file called 'AUTOEXEC.BAT' which should reside in whatever's Windows' equivalent to the root dir, i.e. something like 'C:\'.
     
    Sven-Thorsten Fahrbach, Jul 28, 2005
    #3
  4. wrote:
    > Greetings, I just installed perl v5.8.7 onto a 2003 server box. I can
    > only seem to get perl -v to run on the command line only when I cd
    > into the c:\perl\bin directory.
    >
    >> From the commad line at any other location I am getting the ... 'is
    >> not

    > recognised as an internal or external command, operable program or
    > batch file error'.


    It appears c:\perl\bin is not in your path

    > I am plannign on running MRTG on this box and I am sort of new to
    > perl.


    Has nothing to do with Perl, would be the same for any other program, too.

    > I got mrtg to run on one of my workstations with win2k but I am
    > stumbling with this 2003 server.
    >
    > Is it an IIS issue?


    What does IIS have to do with Perl?

    > Is it a permissions issue?


    Unlikely because you said you can run perl.exe if you cd to c:\perl\bin

    jue
     
    Jürgen Exner, Jul 28, 2005
    #4
  5. Sven-Thorsten Fahrbach wrote:
    > On 28 Jul 2005 06:12:59 -0700
    > "it_says_BALLS_on_your forehead" <> wrote:
    >
    >> i'm not familiar with running Perl on a Windows box, but it sounds
    >> like you need to set your PATH Environment variable to include the
    >> absolute path to the location of your Perl.

    >
    > I've only used Win98,


    Which happens to be quite different from Win2k3. I'm not even quoting your
    suggestion, it's so way off. To set the path just see the manual/help files
    for your OS.

    The OP didn't tell us which distribution he installed. Had he used
    ActiveState then he would have had the option to have the installer do it
    automatically.

    jue
     
    Jürgen Exner, Jul 28, 2005
    #5
  6. Guest

    I created a system variable named 'perl' and gave it the value of
    c:\perl\bin

    'that is where my perl.exe file is located'

    Still no joy.

    I created a test .pl file as described by activestate to see if my web
    server config is ok, adn that did work. I am perplex'd as to why I
    cannot get anythign to run from teh command line though. I am dead in
    the water regarding mrtg until I can get this working.
    Thanks
     
    , Jul 28, 2005
    #6
  7. Tuan Bui Guest

    you need to find your PATH environment variable and append
    "c:\perl\bin" to the end (with a separator). I don't think you need a
    PERL system variable.

    Tuan
     
    Tuan Bui, Jul 28, 2005
    #7
  8. Guest

    I have a 'user variable for administrator' variable named 'PATH' and
    this is the value

    €·øwÿÿÿÿò|ôw³sôwósôw


    That's right, gibberish

    Then below that under system variables, I have a variable named 'Path'
    that has

    C:\Perl\bin\;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\PROGRA~1\CA\SHARED~1\SCANEN~1

    for the value.

    I'm still lost. Thanks
     
    , Jul 28, 2005
    #8
  9. Tuan Bui Guest

    wrote:
    > I have a 'user variable for administrator' variable named 'PATH' and
    > this is the value
    >
    > €·øwÿÿÿÿò|ôw³sôwósôw
    >
    >
    > That's right, gibberish
    >
    > Then below that under system variables, I have a variable named 'Path'
    > that has
    >
    > C:\Perl\bin\;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\PROGRA~1\CA\SHARED~1\SCANEN~1
    >
    > for the value.
    >
    > I'm still lost. Thanks


    And running "perl" from the command line still doesn't work? Hmm...
    try changing your 'PATH' environment variable under user variables to
    "C:\Perl\bin'. I don't think the gibberish is essential to your system
    so you can get rid of it.
     
    Tuan Bui, Jul 28, 2005
    #9
  10. prawn Guest

    wrote:
    > I have a 'user variable for administrator' variable named 'PATH' and
    > this is the value
    >
    > €·øwÿÿÿÿò|ôw³sôwósôw
    >
    >
    > That's right, gibberish
    >
    > Then below that under system variables, I have a variable named 'Path'
    > that has
    >
    > C:\Perl\bin\;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\PROGRA~1\CA\SHARED~1\SCANEN~1
    >
    > for the value.
    >
    > I'm still lost. Thanks


    All that springs to mind is that you have not started a new command
    window since amending your path environment variable. Unlikely though
    it is, it's all I can think of.

    --
    p
     
    prawn, Jul 28, 2005
    #10
  11. prawn Guest

    prawn wrote:
    > wrote:
    >>
    >> I'm still lost. Thanks

    >
    >
    > All that springs to mind is that you have not started a new command
    > window since amending your path environment variable. Unlikely though
    > it is, it's all I can think of.


    <Bad form>

    Type "set" from your command line. Your path environment will be there.

    </bf>

    --
    p
     
    prawn, Jul 28, 2005
    #11
  12. Guest

    Tim, your suggestion work'd. Do I have anything to worry about by
    removing that PATH variable?

    Here are the results from 'set' from prawns guidence below

    OS=Windows_NT
    Path=C:\Perl\bin\;
    GRA~1\CA\SHARED~1\
    PATHEXT=.COM;.EXE;
    perl=C:\Perl\bin
     
    , Jul 28, 2005
    #12
  13. Tintin Guest

    "" <> wrote in message
    news:...
    > Greetings, I just installed perl v5.8.7 onto a 2003 server box. I can
    > only seem to get perl -v to run on the command line only when I cd into
    > the c:\perl\bin directory.
    >
    >>From the commad line at any other location I am getting the ... 'is not

    > recognised as an internal or external command, operable program or
    > batch file error'.
    >
    > I am plannign on running MRTG on this box and I am sort of new to perl.
    > I got mrtg to run on one of my workstations with win2k but I am
    > stumbling with this 2003 server.
    >
    > Is it an IIS issue? Is it a permissions issue?


    Neither. IIS does not run programs from the command line.

    What Perl distribution did you install? If it was ActivePerl or IndigoPerl,
    then they work straight out of the box without having to do any fiddling.
     
    Tintin, Jul 30, 2005
    #13
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. JZ
    Replies:
    2
    Views:
    9,671
  2. Ivan Shevanski
    Replies:
    3
    Views:
    399
    Mike Meyer
    Jul 1, 2005
  3. Ivan Shevanski
    Replies:
    1
    Views:
    386
    Peter Hansen
    Jul 1, 2005
  4. Brad Winborg
    Replies:
    5
    Views:
    150
    Brad Winborg
    Mar 1, 2009
  5. Replies:
    2
    Views:
    164
    Tad McClellan
    Mar 26, 2005
Loading...

Share This Page