Ubuntu Setup

download Ubuntu Setup

If you can't read please download the document

Transcript of Ubuntu Setup

For 11.10 and 12.04 you can override theme color settings by following what I wrote here: http://askubuntu.com/questions/124414/how-to-customize-window-borders-andcontrols/153741#153741 Things to backup Files and Directories 1.) /etc/apache2/httpd.conf /etc/apache2/ports.conf /etc/apache/sites-available and sites-enabled 2.) /etc/hosts 3.) ~/Documents 4.) ~/books-and-courses 5.) ~/public_html 6.) ~/Pictures 7.) ~/Music 8.) ~/Videos 9.) ~/ZendFramework1-Doctrine2 10.) ~/lampon and ~/lampoff 11.) ~/.bash_alias 12.) ~/.bashrc 13.) ~/.vimrc 14.) export all databases to SQL tarred and zipped. 15.) Evolution mail, contacts, calendar is stored in ~/.local/share/evolution You can also backup my Evolution Email and Calendar and Contacts by exporting them. How to Determine if your cpu is 64 bits-enabled: If you are running Linux or have access to Live Linux media, open the terminal prompt and run: grep --color=always -iw lm /proc/cpuinfo

If this command returns lm (Long Mode) as one of the flags, then your processor is capable of 64-bit. If you're running Windows, download, install, and run CPU-Z to check for AMD64 (AMD processors) or EM64T (Intel processors). Set Nautilus default options Edit->Preferences->Views tab See https://help.ubuntu.com/11.04/ubuntu-help/nautilus-views.html Unity Settings Be sure that the compiz-settings-manger is installed. Start it (System-> CompizConfig Settings Manager). Select the Uubuntu Unity Plugin. This will display the settings for Unity, including the Launcher's autohide setting. Immediately After Installing # sudo apt-get update && sudo apt-get upgrade # sudo apt-get install aptitude ubuntu-restricted-extras # sudo apt-get install vim-gnome vim pcregrep See https://help.ubuntu.com/community/RestrictedFormats for info about ubuntu-restrictedextras. To add medibuntu follow the directions on the Mediabuntu site: sudo -E wget --output-document=/etc/apt/sources.list.d/medibuntu.list http://www.medibuntu.org/sources.list.d/$(lsb_release -cs).list && sudo apt-get --quiet update && sudo apt-get --yes --quiet --allow-unauthenticated install medibuntu-keyring && sudo aptget --quiet update Install medibuntu library for play DVDs # sudo aptitude install libdvdcss2 Add Bash Aliases For pcregrep, etc. Add German Language Support System->Keyboard->Layouts and Add German. Toggle key is Shift+Caps Lock. To move mbox exported email to another client To move mbox export email to another client do, follow this guide: http://opensrclinux.blogspot.com/2011/01/exporting-mail-from-evolution-to.html. Copy only files without an extension. Nvidia drivers Note: I found having the latest Nvidia driver is not necessary! However, this is how you would

install it. You can install the latest nvidia video driver/configurator by using x-update ppa, which is at: https://launchpad.net/~ubuntu-x-swat/+archive/x-updates These are: nvidia-current, nvidia-settings, and libva1 After adding the ppa mentioned in the link above, simply do: # sudo aptitude udpate # sudo update-manager /or sudo aptitude full-upgrade The three updates will be available. After installing, logout, then login.

Enable Software Partners In the Software Center, go to Preferences and click on Canonical Partners. Text Clarity To improve font clarity/sharpness follow the suggestions here: https://wiki.ubuntu.com/Fonts#Links_to_fonts. And as suggested, go to Appearance >Fonts >Details. Set: 1. Smoothing to Subpixel (LCD) 2. 3. Hinting to None . This really helped!! Subpixel order to RGB.

Install the MS true type fonts: # sudo aptitude install ttf-mscorefonts-installer. Note: This may be part of ubunturestricted-extras? Copy Tahoma and SegoeUI from your Windows system: # sudo cp /media/HP/Windows/Fonts/tahoma* /media/HP/Windows/Fonts/segoe* /usr/share/font/truetype/msttcorefonts/ Question: Do I also need symlink like many of the truetype fonts? Note: msttcorefonts are part of ubuntu-restricted-extras. After copying, always rebuild the font cache: # sudo fc-cache -f -v This is necessary to rebuild the font information. After running fc-cache, you will manually need to reset Font Hinting to your preferred settings (say, None), as it will be set to slight (or something like that) when fc-cache is run.

Changing Evolution Fonts You can go to Edit->Preferences->Mail Preferences. Unclick the Message Fonts box Use Same Fonts as other applications and choose a different font for the Standard Font (which defaults to Monospace 13) and Fixed Width Font. The Standard Font is used when viewing HTML emails. The Fixed Width Font is used when viewing plain text emails. Font Options dialog explanation Appearance->Font->Help button I choose these fonts: Application Font (for Window titlebars, menus, etc): Tahoma Document Font: Verdana The other settings, I kept as there were. Terminal Console Font: Lucida Sans Typewriter Lucida Sans Typewriterand the other Lucida Fontscan be copied fron Windows\Fonts. Note: I believe Netbeans needs Sun's JRE or JDK to work properly rather than open-java6-jre. However, sun-java6 is only available as a ppa now. See http://ubuntuguide.net/install-sunjava-6-jrejdk-from-ppa-in-ubuntu-11-04 $ sudo add-apt-repository ppa:ferramroberto/java $ sudo apt-get update Then, install java jre: $ sudo apt-get install sun-java6-jre sun-java6-plugin Install JDK by the command: $ sudo apt-get install sun-java6-jdk After doing: # sudo aptitude install sun-java6-font sun-java6-jre rebuild the font cache: sudo fc-cache -f -v. Then choose Lucida Sans Typewriter, Regular, size 14 as the Terminal Console font. NOTE: see http://www.microsoft.com/typography/fonts/font.aspx?FMID=1109 for a source for Lucida Sans Typewriter because sun-java6-font isn't available any longer. It is available in my Windows\Fonts\ folder!!!! See this link for some thoughts: http://www.techsupportalert.com/content/ubuntu-tips-and-tricks.htm says to do this after installing new fonts: # sudo fc-cache -f -v

Grep php source code more easily #!/usr/bin/env bash find . -name "*.php" | xargs pcregrep -nH $1 Gedit Regular Expressions Plugins 1. To search files # sudo aptitude install gedti-developer-plugins 2. To do RegEx within gedit edit window, see http://halfhourhacks.blogspot.com/2008/03/gedit-regular-expression-plugin.html

Vim matchit plugin This allows you to match xml and html tags: http://www.vim.org/scripts/script.php? script_id=39 Ubuntu Theme Appearance->Theme I chose Clearlooks (which is part of gtk-engines, which is installed by default) which I then customizedby clicking on the Customize.. buttonand choosing Clearlooks Classic for controls. This really helped because before the background was sort of washed out and I didn't realize it. Note: For GTK 3 and Ubuntu 12.04, I have bookmarked several Clearlooks-like themes, and I believe I can get the the Clearlook Classic Controls by simply using these colors: Appearance Preferences-> Theme-> Customize Theme -> Colors Item to Customize Windows Input Boxes Selected Items Tooltips Background Color #EDE9E3 = r: 237. g: 233, #000000 = black b: 227 #FFFFFF = r: 255, g: 255, b: 255 #5598D7 = r: 85, g: 152, b: 215 #5598D7 = r: 85, g: 152, b: 215 #000000 = black #ffffff = white #000000 = black Text Color

Appearance Preferences-> Theme-> Customize Theme -> Colors

Note: For Ubuntu 12.04 changing the Window Theme using gnome-tweak-tool to change seems to be the only way to change Window border color. Desktop Background Appearance->Background->Get more backgrounds online I changed to this gnome 1600x1200 wallpaper.

Netbeans Fonts I am installing Sun's JDK, in order to see if the IDE fonts are crisper (they are bad with OpenJDK), from http://www.oracle.com/technetwork/java/javase/downloads/index.html See http://linux-buddy.blogspot.com/2011/10/install-java-170-on-ubuntu1110.html and http://blog-nikolavp.rhcloud.com/2010/05/installing-jdk7-in-ubuntu.html Use the Twig plugin for hilighting Twig code: http://plugins.netbeans.org/plugin/37069/php-twig

Connecting via Samba to Windows 7 See http://www.liberiangeek.net/2011/04/connect-ubuntu-11-04-and-windows-systems-viasambapart-one/ HP Printer HP supports linux. First download the hplip software from http://hplipopensource.com/hplipweb/gethplip.html. Then dowload Prevent Screensaver from Locking Keyboard System Settings Screen Saver Preferences. Change Regard computer as idle after and uncheck Lock screen when Screensaver is active. Ubuntu Multimedia conversion Install ffmeg, and WinFF, a GUI interface for ffmepg. http://ubuntuguide.org/wiki/Ubuntu:Karmic#Audio_.2F_Video_conversion calls ffmeg swissarmy knife of video and audio format conversion. Apache2 setup For information on the Ubuntu MySql, Apache and PHP package, see https://help.ubuntu.com/community/ApacheMySQLPHP and https://help.ubuntu.com/11.04/serverguide/C/httpd.html. I installed these: #sudo aptitude install libapache2-mod-php5 mysql-server phpmyadmin php5-xdebug phpmime-type php-pear php5-gd php5-mysql php5-imagick php5-mcrypt phpunit php-apc php5intl I then created ~/lampon and ~/lampoff to start and stop apache2 and mysql. I altered php.ini for apache2 and cli as follows:

See http://netbeans.org/community/releases/70/install.html Installed Netbeans and changed the IDE font size using ~/netbeans-7.0.1/etc/netbeans.conf, adding --fontsize 16. I made these changes: 1a. Edit /etc/apache2/httpd.conf and add: ServerName localhost (Or does this go in /etc/apache2/sites-available/default?)

Edit /etc/hosts and add: 127.0.0.1 localhost Restart apache2: # sudo apache2ctl restart 1b. Per the comments in /etc/apache2/mods-available/php5.conf, I commented out the lines below so php would work in user directories: SetHandler application/x-httpd-php SetHandler application/x-httpd-php-source # To re-enable php in user directories comment the following lines # (from to .) Do NOT set it to On as it # prevents .htaccess files from disabling it. # Kurt: added these comments # # # # php_admin_value engine Off

# 1c. Enable mod-rewrite:

# sudo a2enmod rewrite # sudo /etc/init.d/apache2 restart 2. I modified /etc/apache2/sites-available/default, which is the configuration for the default site, for those sites which have no specific configuration file. Note: If you code expects DocumentRoot to have an ending slash, it wouldn't work. ServerAdmin webmaster@localhost # Kurt: Commented out the line below and added a different DocumentRoot # DocumentRoot /var/www DocumentRoot /home/kurt/public_html Options FollowSymLinks AllowOverride None # Kurt: Commented out the line below, and added # Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/ AllowOverride None Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch Order allow,deny Allow from all ErrorLog ${APACHE_LOG_DIR}/error.log # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. LogLevel warn CustomLog ${APACHE_LOG_DIR}/access.log combined Alias /doc/ "/usr/share/doc/"

Options Indexes MultiViews FollowSymLinks AllowOverride None Order deny,allow Deny from all Allow from 127.0.0.0/255.0.0.0 ::1/128 You also need to make sure that /home/kurt/public_html has read access and execute for both groups and others: chmod g+rx,o+rx ~/public_html chmod -R g+r,o+r ~/public_html/* Explanation of why 'x' permission is needed above: http://www.cyberciti.biz/faq/apache-403-forbidden-error-and-solution/ explains that adding read access is not enough: all parent directories must be at least searchable by the web server in order for the content to be accessible. Add execute permission avoids he 403 Permission Denied errorat least for .html and .php files in ~/public_html. I'm not certain about subdirectories of ~/public_html? 4. Getting Xdebug to work with Netbeans Paste the result of php -i into the textbox at http://xdebug.com/find-binary.php. Then follow the instructions. This will require phpsize, which is in the php5-dev package. After moving the xdebug.so to appropriate subdirectory indicated, add these entries to /etc/php5/conf.d/xdebug.ini: xdebug.remote_enable=on xdebug.remote_handler=dbgp xdebug.remote_host=localhost xdebug.remote_port=9000 and restart php: /etc/init.d/apache2 restart 5. Installing Doctrine # sudo pear channel-discover pear.doctrine-project.org # sudo pear channel-discover pear.symfony.com # sudo pear install -a pear.doctrine-project.org/DoctrineORM Create symlink:

$ sudo ln -s /usr/share/php/Symfony /usr/share/php/Doctrine/Symfony 6. Installing Zend Framework. Download Zend Framework and uncompress/tar it. Move ./library/Zend and extra/library/ZendX to /usr/share/php. 7. Install phpunit: sudo pear channel-discover pear.phpunit.de sudo pear channel-discover components.ez.no sudo pear install -a phpunit/PHPUnit I'm not sure if there is a phpunit binaryI suspect there isthat is part of the Ubuntu package phpunit: #aptitude install phpunit 8. PHP's include_path. Edit /etc/php5/apache2/php.ini and change the include_path to: include_path = .:/usr/share/php Edit /etc/php5/cli/php.ini include_path = .:/usr/share/php:/home/kurt/netbean-xxxxx/php/zend, where xxxx is the currrent netbeans version number. The netbeans section is needed by the Netbeans IDE to provide the Zend menu item when you right click on your Zend Framework project. Adding Firefox Search plugins Add the Add to Search Bar add-on, this will allow you to right-click in any site's search box and add it as a search plugin. Amazon mp3 installer You need to install the prerequisite debs, which are at: https://answers.launchpad.net/ubuntu/ +question/117260 Netbeans IDE fonts Install sun-java6-jre and sun-java6-fonts. Then uninstall/reinstall netbeans and it will detect Sun's JRE (in preference to the open-6-jre), and it will save this setting in netbeans.conf. Using sun-java6-jre gives slightly better fonts. # aptitude install sun-java6-jre sun-java6-fonts

Note: I simply copied Lucida Sans Typewriter from Windows\Fonts The various look--and--feels can be specified on the command line or in netbeans.conf are discussed at http://wiki.netbeans.org/FaqCustomLaf. Abbreviations for the look-and-feels mentioned at http://wiki.netbeans.org/NBLookAndFeels are: 1. Windows 2. Metal 3. GTK 4. Nimbus So you can just do laf Windows, for example. Substance LookandFeel Plugin It adds itself to Tools->Options->Miscellaneous. You can unclick Enable Substance Look and Feel Skinning Engine, to deactivate. The Mist Aqua feel is nice. The instructions are at: http://kenai.com/projects/nbsubstance/pages/Home. Go to Tool>Plugins->Downloaded, then to Add Plugin, and select the directory to which you have downloaded the three .nbm files. LibreOffice Wizards You need to install the add-on Office Productivity Suite arch independent Java support files, in order for the wizards to work. Synthetica Look-and-Feel Plugin and themes See http://www.jyloo.com/news/?pubId=1308209905000

PEAR install of PHPUNIT This is from taken from http://stackoverflow.com/questions/5022894/phpunit-wrong-path: The PEAR channel (pear.phpunit.de) that is used to distribute PHPUnit needs to be registered with the local PEAR environment. Furthermore, component that PHPUnit depends upon are hosted on additional PEAR channels. pear channel-discover pear.phpunit.de pear channel-discover components.ez.no pear channel-discover pear.symfony-project.com This has to be done only once. Now the PEAR Installer can be used to install packages from the PHPUnit channel: pear install -a phpunit/PHPUnit

Zend Framework's zf.sh tool: # # # # sudo sudo sudo sudo cp cp cp cp -R ~/temp/ZendFramework-1.11.11/library/Zend /usr/share/php -R ~/temp/ZendFramework-1.11.11/extras/library/ZendX /usr/share/php ~/temp/ZendFramework-1.11.11/bin/zf.sh /usr/bin ~/temp/ZendFramework-1.11.11/bin/zf.php /usr/bin

Edit /etc/environment and add: ZEND_TOOL_INCLUDE_PATH=/usr/share/php VirtualBox To get VirtualBox Guest Addtions to work with Ubuntu 12.04 as the guest, you should install VirtualBox 4.1.14. The version that is available as of 7/9/12, on 11.04, is 4.0.4. This link shows how to install VirtualBox 4.1.14 from a ppa: https://www.virtualbox.org/wiki/Linux_Downloads Picasa Use the Picasa Font Settings program that is installed when Picasa is installed to set the GUI font size. General Comments Sometimes after installing a package the UI controls revert to a Windows 95 look-and-feel. Logging out and then in seems to correct this. Cinnamon Desktop PPA: http://lotphelp.com/lotp/install-linux-mints-cinnamon-desktop-ubuntu