Search code examples
perlunc

Does 'use lib' work for UNC paths?


My hosted scripts have been moved and no longer work.

The specified CGI application misbehaved by not returning a complete set of HTTP headers.

I notice that someone at my host company has modified my scripts so that where I used to have

use lib 'd:/myorig/LIB';

I now have

use lib '//newhost/LIB';

Should this work?

I tried 1800 INFORMATION's suggestion and ran the minimal script of

#!perl -w
use lib '//whatever/lib';
print "success";

...which gave the same result.

Update: ysth's suggestion of FatalsToBrowser did indeed reveal more information. It looks like the path (added by someone from the hosting company) might be wrong.

Update2: The hosting company now says that these scripts, unchanged from the previous host mind, are throwing lots of syntax errors. "Since we cannot debug your scripts for you we suggest you contact the original programmer and ask them for help". <grinds teeth>

Partial Resolution: The hosting company finally realised they hadn't set permissions correctly. They still aren't right, and (aargh) they don't allow site owners to set folder permissionsn, not even on folders within their own sites.


Solution

  • No the path is incomplete it needs both a server name and a complete path. It is a bad practice as well because it requires that two machines be monitored rather than one for your application to function.