Type the full pathname of a J2SE installation (or Ctrl-C to quit), the path will be stored in ~/.sqldeveloper/jdk
/usr/lib/jvm/java
29 października 2013
sqldeveloper
28 października 2013
sqlplus – zmienna
export LD_LIBRARY_PATH=”/usr/lib/oracle/12.1/client64/lib/”
23 października 2013
Instalacja zwykłych RPMów
Mamy RPMa i chcemy go zainstalować. Używamy komendy:
rpm -Uhv nazwa_pakietu.rpm
rpm -Fhv nazwa_pakietu.rpm
Parametr -ihv spowoduje zainstalowanie pakietu jeżeli spełnione są wszystkie wymagania, jeżeli nie wyświetlone zostaną brakujące elementy lub inne błędy na jakie trafił instalator. Wersja -Uhv różni się tym od -ihv tym że jeżeli mamy starszą wersję danego programu to zostanie on zaktualizowany (ihv zainstalowałby RPMa jako 2 wersję), jeżeli nie ma to zostanie on standardowo zainstalowany. Wersja -Fhv tylko aktualizuje. Jeżeli nie mamy zainstalowanej starszej wersji to RPM nie zostanie zainstalowany. Usunięcie RPMa przeprowadzamy tak:
Polecenie | Opis |
rpm -qip nazwa_pakietu.rpm | Wyświetlone zostaną dane o pakiecie takie jak opis, autor, strona projektu i inne. |
rpm -q nazwa_aplikacji | To polecenie zwróci numer zainstalowanej wersji aplikacji jeżeli oczywiście jest zainstalowany |
rpm -qa | Wyświetla listę wszystkich zainstalowanych RPMów wraz z numerem wersji |
rpm -qai | Wyświetla szczegółowe opisy dla każdego zainstalowanego RPMa |
rpm -qf /folder/x/plik_lub_folder | Określa nazwę pakietu, którego elementem jest wskazany plik/katalog |
RPMy źródłowe
Komenda jest następująca:
Odpalony zostanie pakiet a zawarty w nik kod źródłowy będzie kompilowany. Do tego potrzebne są odpowiednie biblioteki i w przypadku bardziej złożonych programów będziemy musieli je ściągnąć i zainstalować. Instalator powie nam czego brakuje.
Wynik:
/root/rpmbuild/RPMS/x86_64
Remote Display With the X – Window System
ssh -X login@haslo
http://www.softprayog.in/troubleshooting/x-window-remote-display
18 października 2013
Multiple Java versions.
14 października 2013
linux cloning (network interfaces problem) (eth0)
For years we’ve used bash scripting to ensure that all of our server configurations are standardised, so that we can expect servers with the same role to have the exact same configuration profile and exhibit the exact same behaviour. We’re in the process of moving to Chef but we’re not quite there yet. Recently we decided to redesign our network architecture with a higher level of focus around High Availability. This new design introduces Percona XtraDB Cluster and we’re writing our installation and configuration scripts to ensure that our new cluster boxes are both tuned and standardised.
We have base template linux VM’s in both VMWare and Oracle VirtualBox, and also templates that are specific to server roles such as web servers, HAproxy servers or MySQL Cluster servers. If we need to test a new configuration, or add a new node to the cluster, we just clone the appropriate template add some minor configuration and we’re good.
However if you clone a VMWare or Oracle VirtualBox VM, you’ll notice that it kills your network interfaces throwing errors like the one listed below:
#ifup eth0 Device eth0 does not seem to be present, delaying initialisation |
What’s happening here is that when you clone your VM, VirtualBox and VMWare apply a new MAC Address to your network interfaces but they don’t update the linux configuration files to mirror these changes and so the kernel doesn’t firstly can’t find or start the interface that matches it’s configuration (with the old MAC Address) and it finds a new interface (the new MAC Address) that it has no configuration information for. The result is that only your networking service can only start the loopback networking interface and eth0 is dead.
So here’s how we fix it:
- Remove the kernel’s networking interface rules file so that it can be regenerated
# rm -f /etc/udev/rules.d/70-persistent-net.rules
- Restart the VM
# reboot
- UPDATE your interface configuration file
# vim /etc/sysconfig/networking/devices/ifcfg-eth0
Remove the MACADDR entry or update it to the new MACADDR for the interface (listed in this file: /etc/udev/rules.d/70-persistent-net.rules).
Remove the UUID entry
Save and exit the file
- Restart the networking service
# service network restart
SOURCE:
13 października 2013
yum
yum install aaaaa
yum provides aaaaa
yum search aaaa
yum grouplist | less
nautilus sftp ftp connection
Połącz z serwerem:
sftp://user@example.com:22 ftp://user@example.com:21
java – two versions
Maintaining Multiple Java Versions on Red Hat Linux
I had the need to maintain more than one Java version on a Red Hat Linux machine. I was able to install a new version of Java, and then configure the machine to use the new version by default. It’s also very easy to switch back to using the previous version of Java.
The first step is to download the Java version that you want from the Oracle/Java web site. In my case, I downloaded the following file.
Executing this file as root will perform the installation. You’ll, of course, have to make the file executable after download. By default, the installation “wanted” to install Java in the following directory.
I still wanted to make the new installation the default Java used by the machine. Linux has a nice utility called alternatives to do this, and more specifically, the update-alternatives command. With this command, I was able to first register the newly installed Java as a version of Java that would be recognized by the utility, and I was then able to use the utility to make the new version of Java the default version. When I used the utility to make the newly installed Java the default, the /usr/bin/java on the machine was modified to point to the new version.
Here is the script that I used to have the new version of Java recognized by the alternatives utility.
JAVA_HOME=/usr/java/jre1.6.0_27
# The following command added the new java installation as a java alternative.
# The slave commands bring the related commands with it.
update-alternatives \
–install /usr/bin/java java $JAVA_HOME/bin/java 1 \
–slave /usr/bin/javac javac $JAVA_HOME/bin/javac \
–slave /usr/bin/javadoc javadoc $JAVA_HOME/bin/javadoc \
–slave /usr/bin/jar jar $JAVA_HOME/bin/jar \
–slave /usr/bin/keytool keytool $JAVA_HOME/bin/keytool \
–slave /usr/local/java java_home $JAVA_HOME# A web site suggested that these steps would also be required, but they were not
#ln -s /etc/alternatives/java /usr/bin/java
#ln -s /etc/alternatives/javac /usr/bin/javac
#ln -s /etc/alternatives/javadoc /usr/bin/javadoc
#ln -s /etc/alternatives/jar /usr/bin/jar
#ln -s /etc/alternatives/keytool /usr/bin/keytool
#ln -s /etc/alternatives/java_home /usr/local/java
It’s important to make sure that JAVA_HOME is set to point to the new installation directory. The update-alternatives command links multiple Java utility programs together so that when you switch from one Java version to the next, the proper versions of the related tools come with it (note the slave option in the script above). One web site I visited indicated that I would have to update symbolic links, but the links were made automatically when I tried this on Red Hat 5 and 6.
Running the script above does not make the new version of Java the default. It simply registers that version of Java as a known version of java. Run the following command to change the default.
You should see the following after entering the above command.
There are 3 programs which provide ‘java’.Selection Command———————————————–1 /usr/lib/jvm/jre-1.5.0-gcj/bin/java*+ 2 /usr/lib/jvm/jre-1.6.0-openjdk.x86_64/bin/java3 /usr/java/jre1.6.0_27/bin/javaEnter to keep the current selection[+], or type selection number:
I entered 3, and pressed the enter key, and the newly installed version of Java became the default. You can run the update-alternatives command again to change the version back.
I assume that this works on other flavors of Linux as well, but I’ve never tried. I have done this on both Red Hat Linux 5 and 6
SOURCE:
http://mikes-web-site.blogspot.com/2012/02/maintaining-multiple-java-versions-on.html
linux firefox flash
- Przejdź na stronę pobierania odtwarzacza Flash na witrynie Adobe.com.
- Po wyświetleniu monitu, zapisz plik (np. install_flash_player_”wersja”_linux.”procesor”.tar.gz).
- Na górze okna Firefoksa kliknij menu Plik i wybierz Zakończ
- Otwórz okno terminala (w Gnome kliknij menu Aplikacje, wybierz Akcesoria i następnie Terminal).
- W oknie terminala przejdź do katalogu, w którym został zapisany pobrany plik, np. cd /home/user/Downloads.
- Wyodrębnij libflashplayer.so z pobranego pliku używając polecenia tar -zxvf install_flash_player_”wersja”_linux.”procesor”.tar.gz.
- Jako administrator skopiuj wyodrębniony plik libflashplayer.so do podkatalogu plugins znajdującym się w katalogu z twoją instalacją Firefoksa. Na przykład, jeśli Firefox jest zainstalowany w /usr/lib/mozilla użyj polecenia sudo cp libflashplayer.so /usr/lib/mozilla/plugins i po wyświetleniu monitu podaj swoje hasło administratora.
Fedora 64 bit: /usr/lib64/mozilla/plugins
chmod 755 libflasplayer.so
12 października 2013
iwl drivers wifi linux, monitor
check the output of lsmod
and look for iwlwifi
and iwldvm
to see if the module is loaded, if not, you can load it yourself using modprobe -v iwldvm
yum search iwl
you’ll see iwl6000-firmware, iwl6000g2b-firmware, and so on.
lshw – hardware monitor
monitor
xrandr
xrandr –output DVI-1 –right-of DisplayPort-0