Ubuntu Terminal: How to Make a Folder Writable

It is not often that you need to force a folder in Ubuntu to be writable, usually you only sit with this sort of issue when you want to create a space on your web server for users to upload something to or some other similar reason. Anyway, luckily it is a simple matter to make a folder writable via an Ubuntu terminal instance, making use of the classic chmod functionality.

In practice, to make a folder like /home/uploads writable to all, run:

chmod 777 /home/uploads

The value of 7 indicates read, write and execute permissions, with the first 7 standing for the owner, the second for the group and the final one for everyone else.

And that should pretty much do it, though remember a folder with such open permissions is a pretty risky little beast to have lying around.

Nifty.

Related Posts:

  • Linux (and thus Ubuntu) file access permissions often get in your way if you aren't a power user, but if you have played around with the Ubuntu terminal for long enough, you should by now be aware of the magical CHMOD command and the way in which it can alter file and folder permissions. The most common way of u ...

  • When you find yourself using the terminal in Ubuntu or any other Linux distribution for that matter, it is always pretty handy to know in which directory you are currently working. In Linux terms, this is known as your current working directory. To quickly find out where you are in the system, simply use the pwd ...

  • When using the terminal to navigate your way through your Ubuntu or any other Linux distro, it is actually pretty easy to quickly see how big a particular directory or folder is in terms of size. The command to use is du, short for Disk Usage. It's main purpose is to gather and summarize how much of your disk sp ...

  • To list the files and folders of a directory while running around in an Ubuntu terminal you use of course the classic ls list command. But what if the list it returns is particularly long? Is there a way to pause a ls listing so that you can follow what is going on? The easiest way to achieve this is by piping t ...

  • There are two commands which you can use to create an user account on an Ubuntu Server installation. The first command is the adduser command which is not very flexible but is user friendly in that it prompts you for data with each and every step in the creation process. The other more flexible command is userad ...

About Craig Lotter

Craig Lotter is an established web developer and application programmer, with strong creative urges (which keep bursting out at the most inopportune moments) and a seemingly insatiable need to love all things animated. Living in the beautiful coastal town of Gordon's Bay in South Africa, he games, develops, takes in animated fare, trains under the Funakoshi karate style and for the most part, simply enjoys life with his amazing wife and daughter. Oh, and he draws ever now and then too.

  • Shairozan

    This command does more than make a directory writable. 777 Means it is Readable, Writable and Executable by any user and this is ill-advise for any actual implementation. The appropriate way to make a file writable is as follows:

    chmod ug+w filename

    This makes the filename writable for the owning user and its group. You could also do

    chmod o+w filename

    But this makes it writable to all other users, which would be the same as the 777. I would also look into what the octal references (numbers, ie 777, 620) mean.