Ubuntu installation Memorandum
I. Upgrade and roll back the kernel
1. Install ubuntu
We recommend that you use a stable kernel version in the android development environment. We recommend that you install ubuntu12.04.
2. Upgrade the kernel version
As ubuntu12.04 is prone to freezing, we recommend that you upgrade the kernel to kernel 3.5.
Run the following command to upgrade the instance:
Apt-get install linux-generic-lts-quantal xserver-xorg-lts-quantal
3. roll back the kernel version
If you accidentally upgrade the kernel to an unstable high version during kernel upgrade, you can delete unnecessary
A. Check the installed kernel version.
Dpkg -- get-selections | grep linux-image
B. Delete unwanted kernels
Sudo apt-get remove "unwanted kernel versions"
2. Install a wireless NIC Driver
1. Check the model of the wireless network card and determine the driver version.
2. install different wifi Drivers Based on Different kernel versions
3.2 kernel installation: http://download.csdn.net/detail/wlwl0071986/8811945
3.5 kernel installation: http://download.csdn.net/detail/wlwl0071986/8811919
3. Compile the driver source code and install the driver.
Make, make install, insmod 8188.ko
3. Install sogou Input Method in ubuntu
1. Add Source
Sudo add-apt-repository ppa: fcitx-team/nightly
2. Update Source
Sudo apt-get update
3. Install fcitx
Sudo apt-get install fcitx
4. Install the fcitx Configuration Tool
Sudo apt-get install fcitx-config-gtk
5. Install the table-all software package of fcitx
Sudo apt-get install fcitx-table-all
6. Install the im-switch tool.
Sudo apt-get install im-switch
7. Enter "fcitx" in the search bar in the upper left corner. The input method icon appears. The installation is complete.
8. In the system settings, set the system language to "Chinese-pinyin"
4. Install gcc4.4 in ubuntu12.04
1. ubuntu12.04 install gcc4.6 by default. We need to manually install gcc4.4
Sudo apt-get install gcc-4.4 g ++-4.4g ++-4.4-multilib gcc-4.4-multilib
2. Set gcc4.4 as the default Compiler
Update-alternatives -- install/usr/bin/g ++-4.4 100
Update-alternatives -- install/usr/bin/g ++-4.6 50
Update-alternatives -- install/usr/bin/gcc/usr/bin/gcc-4.4 100
Update-alternatives -- install/usr/bin/gcc/usr/bin/gcc-4.6 50
Update-alternatives -- install/usr/bin/cpp-bin/usr/bin/cpp-4.4 100
Update-alternatives -- install/usr/bin/cpp-bin/usr/bin/cpp-4.6 50
3. Check whether the gcc version is installed successfully.
Gcc-v
5. Install the adb Tool
1. Install adb through apt-get
Sudo add-apt-repository ppa: nilarimogard/webupd8
Sudo apt-get update
Sudo apt-get install android-tools-adb
2. Copy the adb tool compiled by the system for installation.
Cp ~ /Android/out/host/linux-x86/bin/adb/usr/local/bin
3. Connect the android device to your computer and view the usb device through lsusb
Bus 001 Device 002: ID 8087: 0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087: 0024 Intel Corp. Integrated Rate Matching Hub
Bus 003 Device 002: ID 03f0: 094a Hewlett-Packard
Bus 001 Device 001: ID 1d6b: 0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b: 0002 Linux Foundation 2.0 root hub
4. Create the adb_usb.ini file and write the id
Sudo echo 0x1f3a> ~ /. Android/adb_usb.ini
5. Add Permissions
Sudo vim/etc/udev/rules. d/70-android.rules
Add the following content. Note that the red part corresponds to the id obtained by lsusb.
SUBSYSTEM = "usb", ATTRS {idVendor} = "1f3a", ATTRS {idProduct} = "1002", MODE = "0666"
6. Restart the usb service.
Sudo chmod a + rx/etc/udev/rules. d/70-android.rules
Sudo service udev restart
7. Restart the adb Service
Adb kill-server
Sudo adb start-server
Adb devices
Vi. Problem Solving of ubuntu12.04
1. Solve the Problem of garbled txt text
Gsettings set org. gnome. gedit. preferences. encodings auto-detected "['utf-
8 ', 'gb18030', 'gb2312', 'gbk', 'big5', 'current', 'utf-16']"
2. An error occurred while installing the software package with apt-get.
E: Sub-process/usr/bin/dpkg returned an error code (1)
Solution:
Sudo mv/var/lib/dpkg/info/var/lib/dpkg/info_old // rename the info folder
Sudo mkdir/var/lib/dpkg/info // create a new info folder.
Sudo apt-get update
Sudo apt-get-f install
Sudo mv/var/lib/dpkg/info/*/var/lib/dpkg/info_old // After performing the previous operation, some files will be generated in the new info folder.
All these files are moved to the info_old folder.
Sudo rm-rf/var/lib/dpkg/info // Delete the info folder you created
Sudo mv/var/lib/dpkg/info_old/var/lib/dpkg/info // rename the previous info folder
3. the Kernel driver not installed (rc =-1908) appears in VirtualBox)
A. Add the current user to the vboxusers User Group
Sudo usermod-G vboxusers-a andee
B. Install the following components:
Sudo apt-get install linux-headers-'uname-R'
Sudo apt-get install virtualbox-dkms
Sudo dpkg-reconfigure virtualbox-dkms)
C. Load
Ll/dev/| grep vboxdrv
Sudo modprobe vboxdrv
D. reinstall and start vboxdrv
Sudo/etc/init. d/vboxdrv setup
VirtualBox