Arc Forumnew | comments | leaders | submitlogin
Permission Denied; errno=13?!
1 point by system42 5763 days ago | 6 comments
I'm starting to become familiar with Arc, and I'm testing the forum software on a vps of mine, trouble is I'm having some weird difficulty.

I've been able to run the forum software on a virtual fedora box on my local machine, but when messing with the VPS I get a Permission denied error for the /logs/news* files.

Now I've set chmod 777 for the entire directory, so everyone should have read/write access, but none the less here's the output:

open-output-file: cannot open output file: "/root/Desktop/nex/arc/logs/news-2010-02-13" (Permission denied; errno=13)

==== context ==== svrlog gs2060 gs2059 gs1059 handle-request-thread

Function call on inappropriate object nil (delay)

-----

So I can get it working on my local virtual machine with the same settings, but on my VPS box it fails.

I've also gotten it working on a Mac OS 10.5 box I have at work, with no permission errors.

I'll admit my unix skills are a bit rusty, so maybe I'm overlooking some simplistic permission settings.

Any help would be cool, thanks.



1 point by aw 5763 days ago | link

Please copy and paste into a comment here the output of

  ls -la /root/Desktop/nex/arc/logs
and, tell us what user you are running the mzscheme command as?

-----

1 point by system42 5763 days ago | link

total 36

drwxrwxr-x 2 root root 4096 Feb 13 16:43 .

drwxrwxr-x 4 root root 4096 Feb 13 16:43 ..

-rwxrwxr-x 1 root root 7275 Feb 13 16:43 news-2010-02-10

-rwxrwxr-x 1 root root 18968 Feb 13 16:43 srv-2010-02-10

As you can see from the 02-10 files, I had the site working a few days ago on my fedora box.

Also I'm running mzscheme under root

-----

3 points by aw 5763 days ago | link

Line 14 of srv.arc in arc3.1 switches the user id that Arc (mzscheme) is running under.

The purpose of this is to allow port 80 to be opened by mzscheme, and then to switch to a non-privileged user to run the server under.

If you don't need to open port 80, or you're going to run the Arc server as root, simply remove that line.

Alternatively, choose a user id to run the Arc server under, make the Arc directory and all its files owned by that user, and change the "2" in the setuid command to the numeric user id of that user.

-----

1 point by evanrmurphy 5739 days ago | link

I was having a duplicate of system42's problem, and commenting out line 14 fixed it for me. Thank you, aw!

-----

1 point by system42 5763 days ago | link

Ahh I see, makes sense. Thanks for the help, running smooth now.

-----

1 point by system42 5763 days ago | link

And to clarify, this is once I've complete the command: mzscheme -f as.scm , then (load "news.arc") and finally (nsv) and the server goes live on port 8080, but once I hit the site from a browser, then the permission error displays and the site doesn't launch.

-----