January 16th, 2011
Use the following command to set a user to a primary usergroup. This is a continued discussion from “Add user to a specific usergroup“.
In my example the user is currently a member of “newuser wheel webdev”:
ae@na-unix$ groups newuser
newuser : newuser wheel webdev
The first group listed is the primary usergroup. I want to set the primary usergroup to webdev and remove the group newuser.
This is accomplished by executing the following command:
Read the rest of this entry »
Posted in Server, Tips and Tricks | 1 Comment »
January 15th, 2011
In order to add a user with the user directory you use the useradd command. By default, this is a home directory located at /home/{username}
/usr/sbin/useradd yourname
will create the user yourname, and make the directory /home/{username}
To set the password for the new user use the command passwd. This will give the user a password and activate the account.
/usr/bin/passwd yourname. You will be prompted twice for a password.
Also of note, if you want useradd to create more default directories than just /home/newuser, you can add them to /etc/skel. Anything you add to this directory will be created when you add a new user.
mkdir /etc/skel/www
Posted in Server, Tips and Tricks | No Comments »
January 13th, 2011
Yesterday I was attempting to find the size of a bloated directory. I executed:
man du
Which spit out a bunch of possibilities for the du command. Looking the list over I came up with the following command to output the size of the directory.
Read the rest of this entry »
Posted in Server, Tips and Tricks | No Comments »
December 29th, 2010
On a typical media wiki install zip uploads are blacklisted. On an attempt to upload you’ll most likely receive the following message:
“Files of the MIME type “application/zip” are not allowed to be uploaded.”
You’ll need to check four places:
Posted in Server, Software, Tips and Tricks | 2 Comments »
December 25th, 2010
Unknown to many Mac’s can have slow down issues and file permission issues just like Windows. Fortunately Apple has provided a simple and effective solution within the ulitity applications. The specific application is called “Disk Utility.” If you’ve used this in the past it was likely for partitioning but it also have a nice feature for repairing your disk.
Go to “Applications” > “Ultilities” > “Disk Utility”
Then click your Mac partition/disk and on the right side choose “Repair Disk Permissions”.
It only takes a few minutes but it’s amazing what this small tool can do. I recommend running it ever couple months.
Posted in Software, Tips and Tricks | No Comments »
December 23rd, 2010
I recently installed MediaWiki 1.6 and realized I needed to upload images. I went to the upload screen at http://wiki.example.com/Special:Uploads
I received a message declaring that I was unable to upload. I promptly realized that I hadn’t set the configuration up for uploading. Off I went to vim /var/www/wiki/LocalSettings.php and searched for “upload”. I found the following line:
$wgEnableUploads = true; # Enable uploads
Read the rest of this entry »
Tags: images, mediawiki, uploading, wiki
Posted in Server, Software, Tips and Tricks, Web | No Comments »
December 20th, 2010
Running Unbuntu and Nvidia graphics cards can become an issue in certain cases. I was running a Dell Omniplex 320 with GeForce 8400 GS. I could not get it to display in a proper dual screen mode with the correct resolution. I was able to modify the configuration to do so. The following is my new configuration file.
Read the rest of this entry »
Tags: graphic card, nvidia, Server, tips
Posted in Equipment, Tips and Tricks | No Comments »
December 18th, 2010
Similar to Windows or a Macintosh alias a symbolic link, or sym link, points to an other location. A hard link points directory to a location, a symbolic link does not contain the data in the target file. It simply points to another entry somewhere in the file system. This difference gives symbolic links certain qualities that hard links do not have, such as the ability to link to directories, or to files on remote computers networked through NFS. Also, when you delete a target file, symbolic links to that file become unusable, whereas hard links preserve the contents of the file.
To create a symbolic link in Unix, at the Unix prompt, enter:
ln -s source_file myfile
Tags: links, linux, tips, unix
Posted in Server, Tips and Tricks | No Comments »
December 16th, 2010
To start tomcat:
~/bin/start_tomcat
To stop:
~/bin/stop_tomcat
For error checking:
cat /usr/local/jakarta-tomcat-4.0.1/logs/catalina.out
Tags: issues, Server, tips, tomcat
Posted in Server, Tips and Tricks | No Comments »
December 14th, 2010
I recently started getting duplicate mails in my inbox in Thunderbird. I sought out why this was happening and what I could do to stop it.
What I found was this could happen when new emails are being pulled from the mail server and you get disconnected during that process. Those emails will then be fetched again when Thunderbird reconnects. Thunderbird has a nice hidden variable that defines how it should treat duplicate mails. This was my solution. Read the rest of this entry »
Tags: duplicate, email, mail, thunderbird, tips
Posted in Tips and Tricks, Web | No Comments »