个人工具

“用户讨论:Jinzd”的版本间的差异

来自Ubuntu中文

跳转至: 导航, 搜索
Ubuntu
第12行: 第12行:
 
export classPath=/usr/local/jdk1.8.0_91/
 
export classPath=/usr/local/jdk1.8.0_91/
  
=Ubuntu=
+
Ubuntu=
  
 
<pre>
 
<pre>
 
sudo apt-get update
 
sudo apt-get update
  
sudo apt-get dist-upgrade
+
sudo apt-get dist-upgrade / sudo apt-get upgrade
 
+
----------------------
 
sudo apt-get install postresql-9.5
 
sudo apt-get install postresql-9.5
  
 
sudo apt-get install pgadmin3
 
sudo apt-get install pgadmin3
  
 +
sudo -u postgres psql postgres
 +
 +
\password postgres
 +
----------------------
 +
cd /etc/postgresql/9.5/main
  
 +
sudo nano postgresql.conf
 
</pre>
 
</pre>
  

2016年6月21日 (二) 17:41的版本

Kubuntu 技巧

Shell编程基础

man sudo_root


export JAVA_HOME=/usr/local/jdk1.8.0_91/

export PATH=$JAVA_HOME/bin:$PATH

export classPath=/usr/local/jdk1.8.0_91/

Ubuntu=

sudo apt-get update

sudo apt-get dist-upgrade / sudo apt-get upgrade
----------------------
sudo apt-get install postresql-9.5

sudo apt-get install pgadmin3

sudo -u postgres psql postgres

\password postgres
----------------------
cd /etc/postgresql/9.5/main

sudo nano postgresql.conf

ifconfig

ifconfig

Usage:

ifconfig [-a] [-v] [-s] <interface> [[<AF> ] <address>]
[add <address>[/<prefixlen>]]
[del <address>[/<prefixlen>]]
[[-]broadcast [<address>]] [[-]pointopoint [<address>]]
[netmask <address>] [dstaddr <address>] [tunnel <address>]

Java

Add deb resource path:

sudo add-apt-repository "deb http://archive.canonical.com/ubuntu maverick partner"

sudo apt-get update

sudo apt install sun-java8-jdk

# remove

sudo add-apt-repository -r "deb http://archive.canonical.com/ubuntu maverick partner"

PostgreSQL

For newest Ubuntu 16.04 postgresql is ready to install:

[email protected]:~S sudo apt install postgresql-9.5

Get postgresql ready to use, set password is the first step:

[email protected]:~S sudo -u postgres psql template1

template1=# \password postgres;

or

[email protected]:~S sudo -u postgres psql postgres

postgres=# \password postgres;

Create database:

[email protected]:~S sudo -u postgres createdb JUniverse

sudo -u postgres psql --host=localhost --username=postgres --password

Create user:

[email protected]:~S sudo -u postgres createuser