Find the answer to your Linux question:
Results 1 to 8 of 8
Hey, I am a little bit new to linux (although I am using Mac OS X and its terminal), and I think this *might* be a noob's question - well, ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2010
    Posts
    3

    Unhappy Weird permission change - impossible


    Hey,

    I am a little bit new to linux (although I am using Mac OS X and its terminal), and I think this *might* be a noob's question - well, whatever.

    I have openSuSE 11.2, and just recently I've installed Apache 2.2 on it. I installed php, rewrite and ftp modules - all was OK. I made two accounts which are able to login on the FTP, and should have full access - I made the htdocs (the folder accessible from FTP) have permissions - root and root group should have both read, write and delete permissions. However, when I right clicked the folder >properties > permissions - it said "Folders: Read and write" (or something like that), but "Files: ---"... Always when I wanted to change that, in GUI or terminal - it did the same, it either changed back to --- immediately, or it stayed like that... until I closed the window. When I reopened it, it was the SAME...

    I double-checked - Apache was stopped at the moment. I tried to change the permissions of the enclosing folder - still did the same.

    I do not really understand the Linux filesystem structure yet, but from what I read on internet, I saw that most used install prefix is /usr/local/apache - I installed it there as well. So, I though I shall put the htdocs folder somewhere else - I made a new folder in /var/ called server. But the properties of that folder did the same thing! I.e. it changed back just when I changed it to something else.

    How can I REALLY change these permissions so they won't change back in a second?

    P.S. I AM logged in as root.

  2. #2
    Just Joined!
    Join Date
    Sep 2007
    Posts
    5
    hey,

    I don't know about the SuSE way to do it, but here's the console way:

    1.
    Code:
    cd
    to your current location of htdocs
    2.
    Code:
    chmod -R xxx *
    "-R" means recursive and you need to replace "xxx" with desired permissions and "*" with the files you want (thet is if you don't want all of them).
    For more details on chmod you have google with the manual of chmod and lots of tutorials

    finaly you can check the change:
    3.
    Code:
    ls -la
    this will list ("ls") all the files in the current folder ("a" part means all including hidden files) in a list format including permissions ("l" part)

    hope this helps

  3. #3
    Linux Newbie
    Join Date
    Mar 2007
    Posts
    142
    I wonder if you mix-up two different things?

    If you install apache, that is a web-server for web pages.
    On the other hand you have ftp and that is something different.
    To use ftp, you need to install a ftp-server.
    Most known and used types are pureftp and vsftp (very secure ftp).
    Setting up a ftp server is quite simple.
    You only need to edit a configuration file.
    In the case of vsftp it is vsftp.conf.
    You have to uncomment the lines that you need, but sure you must know what you are doing.
    You can also testing it on your local network if you have one.

  4. $spacer_open
    $spacer_close
  5. #4
    Just Joined!
    Join Date
    Mar 2010
    Posts
    3
    Oh, common... I am not that new to web programming. I was using Apache for a long time, even though it was hosted on some other site computer. I do not want a help in Apache - because I obviously KNOW there is a FTP module that can be installed - so you can easily access and change your site.

    And for mitis2010 - Hm... I thought I stated clearly I TRIED to change permissions using terminal, as well as GUI - both produced the same result (ie. no change)...

    Anyways, does anyone have any idea what can block me from changing FILE permissions even when I am logged as a root and that folder has root:root?

  6. #5
    Linux Newbie
    Join Date
    Mar 2007
    Posts
    142
    Well, what I wanted to say was that a ftp-server has to run on that computer.
    If not, you cannot log-in using ftp.
    But if you use a ftp server this must be pureftp or vsftp for security reasons.
    Any other ftp server is NOT SECURE.
    So you need to see what ftp server you are running on your machine.

    Like all network protocols, it's always a server-client case.
    The clients are ftp programms on the same machine, or on other machines, local or external.

    But I am interested what ftp server they use with apache.

  7. #6
    Just Joined!
    Join Date
    Mar 2010
    Posts
    3
    -.-

    Are you serious? I honestly don't care which of these Apache uses - I went here to ask for what reason I cannot change the file permissions on a folder.

  8. #7
    Linux Newbie
    Join Date
    Mar 2007
    Posts
    142
    Yes I am serious about security!
    But it doesn't seem to bother you, and that's your choice.
    I did find out that apache doesn't use eiter pureftp or vsftp, and that's no good for me.
    But feel fine with what you do.
    Once again my only goal was to give you some thoughts about security matters.
    But when it bothers you please ignore them.

    On the other hand it is a wise thing as you want to understand the Linux filesystem structure.
    But that's quite simple, it just one big folder tree.
    How to change permissions has been said here.
    And need not to be repeated.
    As you did what you are writing, we have no idea what you did wrong.

  9. #8
    Linux Guru gogalthorp's Avatar
    Join Date
    Oct 2006
    Location
    West (by God) Virginia
    Posts
    3,104
    You need to read up on file systems a little

    man chmod

    will give you the man page.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •