Latest 100 public
snipts » ubuntu
showing 1-20 of 49 snipts for ubuntu
-
∞ mysql - conexiones remotas en ubuntu
Si quieres poder conectarte a MySQL desde una aplicación externa (como Navicat) en otra maquina hay que habilitar conexiones remotas. # 1. Hay que editar el archivo /etc/mysql/my.cnf sudo gedit /etc/mysql/my.cnf # 2. Ya en gedit buscamos con ctrl + F "bind-address" sin comillas # Comentamos la linea bind-address = 127.0.0.1 # dejandola así: # bind-address = 127.0.0.1 3. Guardamos el archivo y reiniciamos MySQL sudo restart mysql ---- Listo, con eso podras conectarte a MySQL desde otra aplicación que no esté en el mismo servidor localmente.
-
∞ Install deb packages
$ dpkg -i package.deb -
∞ mount hfs+ (mac) file system on an external drive as read write in ubuntu (linux). depends on: hfsprogs
sudo fsck.hfsplus /dev/sdc1
-
∞ ubuntu - encontrar la ruta de una aplicacion desde terminal
# locate "aplicacion" locate phpmyadmin locate mysql -
∞ Packages to get after a fresh install
### Lista de pacotes ### apt-get install -y unrar p7zip apt-get install -y gparted apt-get install -y compizconfig-settings-manager apt-get install -y gmount-iso apt-get install -y codeblocks codeblocks-dbg apt-get install -y gimp apt-get install -y vlc vlc-plugin-pulse apt-get install -y gtk-recordmydesktop apt-get install -y docky apt-get install -y libglew1.5 glew-utils apt-get install -y libglu1-mesa-dev libglu1-mesa-dev apt-get install -y freeglut3 freeglut3-dev apt-get install -y oxygen-cursor-theme #apt-get install -y adobeair #tentar o 1.5 por link direto apt-get install -y startupmanager apt-get install -y gconf-editor apt-get install -y g++ apt-get install -y gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-multiverse apt-get install -y nethogs ### Latex ### #apt-get install texlive-fonts-recommended texlive-fonts-extra latex209-bin latex-beamer ### Adiciona repositórios ### add-apt-repository "deb http://archive.canonical.com/ lucid partner" #sun-java add-apt-repository ppa:jd-team/jdownloader #jdownloader add-apt-repository ppa:tualatrix/ppa #ubuntu-tweak add-apt-repository ppa:bjfs/ppa #emesene apt-get update ### Instala apps dos repositórios adicionados ### apt-get install -y sun-java6-jre sun-java6-plugin sun-java6-fonts apt-get install -y jdownloader apt-get install -y ubuntu-tweak apt-get install -y emesene ### Dependentes ### apt-get install -y vuze #depende do java ### sources.list ### ### -> Chrome <- ### #################### Modo 1 ########################### #cp /etc/apt/sources.list /etc/apt/sources.list.backup #deb http://dl.google.com/linux/deb/ stable main #wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - #apt-get install google-chrome ######################################################### touch /etc/apt/sources.list.d/google-chrome.list echo "deb http://dl.google.com/linux/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list apt-get update apt-get install -y google-chrome ### tweetdeck ### echo "Baixando AdobeAir 1.5 (.bin)" wget -c http://airdownload.adobe.com/air/lin/download/1.5/AdobeAIRInstaller.bin chmod 755 AdobeAIRInstaller.bin ./AdobeAIRInstaller.bin echo "Baixando TweetDeck (.air) para a pasta atual" wget http://bit.ly/thedeck ### Lembrete ### echo "Instalar Dropbox e tweetdeck na mão"
-
∞ Ubuntu - nautilus, ver la ruta de carpetas
# en la terminal gconf-editor # en el programa que aparece, darle check a Apps > Nautilus > Preferences > Always_Use_Location_Entry
-
∞ ubuntu - agregar drivers para LVM2
sudo -i apt-get install lvm2 modprobe dm-mod vgchange -a y # help lvm help
-
∞ ubuntu - apagar o reiniciar via terminal
# apagar linux sudo poweroff # o sudo shutdown 0 # reiniciar sudo shutdown -r
-
∞ Comandos comunes seteando redes locales en linux
# Donde está la configuración de red? /etc/network/interfaces auto eth0 iface eth0 inet static address 192.168.1.100 netmask 255.255.255.0 gateway 192.168.1.1 # desde la consola seria ifconfig - revisar rdatos de red ifconfig eth0 {IP} - cambiar el IP local, ejemplo ifconfig eth0 192.168.1.2 ifconfig eth0 network {IP} - cambiar mascara de red # extra lsb_release -a | saber version del SO de la maquina hostname | saber el nombre de la maquina
-
∞ Integrate Firefox's notifications with Ubuntu's OSD
sudo aptitude install xul-ext-notify
-
∞ Log in into ubuntu installation from Live CD
requires: terminal from Live CD sudo fdisk -l (get installation drive) sudo mount <installation drive> /mnt sudo chroot mount (now you are root in the hd installation)
-
∞ Installing Webmin from Virtualman Repository on Ubuntu 8.04LTS
# Add this to /etc/sources.list deb http://software.virtualmin.com/gpl/ubuntu virtualmin-hardy main #run the following commands as root (sudo) wget --quiet http://software.virtualmin.com/lib/RPM-GPG-KEY-virtualmin -O - | sudo apt-key add - wget --quiet http://software.virtualmin.com/lib/RPM-GPG-KEY-webmin -O - | sudo apt-key add - apt-get update apt-get install webmin
-
∞ Rollback to previous package version after bad upgrade with Ubuntu 8.04LTS and APT
This will show all the versions of the package in the cache apt-cache show [package name] | fgrep Version: This will install an older version of the package apt-get install [package name]=[version]
-
∞ Another solution to RVM Ubuntu Rails error
$ rvm uninstall 1.9.1 $ rvm install 1.9.1 --with-readline-dir=$rvm_path/.rvm/usr
-
∞ Actualizar Ubuntu sin riesgos
; 1. Como root, hacer un backup del / sudo su - cd / tar -cvf /tmp/mi-dir-raiz.tar --exclude=mnt/* --exclude=dev/* --exclude=proc/* --exclude=tmp/* * ; 2. Te guardas /tmp/mi-dir-raiz.tar en un disco externo. ; 3. Actualizas, y si no te gusta el resultado arrancas desde un live-cd, montas la particion / en /mnt, borras todo el contenido de la actualizacion y restauras ahí tu tar. mount /dev/sdaX /mnt cd /mnt rm -rf * tar -xvf /midiscoexterno/mi-dir-raiz.tar ; 4. Ya solo te queda instalar el grub y reiniciar grub-install --root-directory=/mnt reboot
-
∞ Sound problems in Ubuntu
sudo /etc/init.d/alsa-utils reset /sbin/alsa force-reload
-
∞ update fonts in ubuntu
sudo fc-cache -f -v -
∞ Play music on a remote linux (debian branch) computer via SSH
#I used this technique to play music on a computer with a much better sound system from my laptop. #On the "music server" sudo apt-get install openssh-server mplayer #Once done, on the "controler" computer ssh <username>@<server_name_or_ip> cd /path/to/music/files #If you want to play only one song mplayer song.ext #If you want to play the whole directory mplayer *.ext #In case of multiple extentions (example with mp3, wma and ogg files mplayer *.mp3 *.wma *.ogg #You can control your music server from a windows comuputer with PuTTY
-
∞ Fix non sleep aware modules
# echo 'SUSPEND_MODULES="$SUSPEND_MODULES edimax-driver-name-here' > /etc/pm/config.d/edimax-fix -
∞ rename dirs in gnome
#!/bin/bash # Criado em:Qua 07/Out/2009 hs 10:47 # Last Change: Qua 07 Out 2009 11:49:36 BRT # vim:ft=sh:fdm=syntax:nu: # Instituicao: none # Proposito do script: consertar nome das pastas no ubuntu # Autor: Sérgio Luiz Araújo Silva # site: http://vivaotux.blogspot.com # função será executada se o for usuário comum pessoal (){ FILE=~/.config/user-dirs.dirs # backup echo "criando backup de $FILE" sleep 1 cp $FILE{,.backup} cat <<-EOF > $FILE # This file is written by xdg-user-dirs-update # If you want to change or add directories, just edit the line you're # interested in. All local changes will be retained on the next run # Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped # homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an # absolute path. No other format is supported. XDG_DESKTOP_DIR="$HOME/Desktop" XDG_DOWNLOAD_DIR="$HOME/docs/downloads" XDG_TEMPLATES_DIR="$HOME/docs/modelos" XDG_PUBLICSHARE_DIR="$HOME/docs/share" XDG_DOCUMENTS_DIR="$HOME/docs" XDG_MUSIC_DIR="$HOME/docs/musicas" XDG_PICTURES_DIR="$HOME/img" XDG_VIDEOS_DIR="$HOME/docs/videos" EOF } # função "geral" será executada se for root geral () { FILE=/etc/xdg/user-dirs.defaults # backup cp $FILE{,.backup} echo "criando backup de $FILE" sleep 1 cat <<-EOF > $FILE # Default settings for user directories # # The values are relative pathnames from the home directory and # will be translated on a per-path-element basis into the users locale DESKTOP=Desktop DOWNLOAD=docs/downloads TEMPLATES=docs/modelos PUBLICSHARE=docs/publico DOCUMENTS=docs MUSIC=docs/musica PICTURES=docs/img VIDEOS=docs/videos # Another alternative is: #MUSIC=Documents/Music #PICTURES=Documents/Pictures #VIDEOS=Documents/Videos EOF } [ "$(id -u)" != "0" ] && pessoal || geral


