Linux « Różności …

Różności …

29 września 2015

firefox adding a site to the exception site list

Zaszufladkowany do: Linux — Tagi: — Jacek @ 12:48

Adding a site to the Exception Site List

End-users can access the Exception Site List from the Java control panel.

  1. Use your browser to access the RIA that you normally use.
  2. Copy the URL from the address bar.
    Only choose directory paths ending in a / and not a filename.

    • Right: https://www.example.com/someApplication/
    • Wrong: https://www.example.com/someApplication/filename.html
  3. Open the Java control panel.
    • Windows/Mac – Open your system control panel or System Preferences and choose Java.
    • Linux/Solaris – Run the jcontrol command.
  4. Choose the Security tab.
  5. Click the “Manage Site List” button near the bottom.

https://blogs.oracle.com/java-platform-group/entry/upcoming_exception_site_list_in

2 września 2015

force fsck at root filesystem

Zaszufladkowany do: Linux — Tagi: — Jacek @ 07:56
sudo touch /forcefsck

Then reboot.

or

shutdown -rF now (F - force fsck at boot time)

http://superuser.com/questions/401217/how-to-check-root-partition-with-fsck

2 sierpnia 2015

forticlient

Zaszufladkowany do: Linux — Tagi: — Jacek @ 19:53

apt-get install libgtk2.0-0:i386

apt-get install libsm6:i386

apt-get install libstdc++6:i386

25 lipca 2015

nslookup

Zaszufladkowany do: Linux — Tagi: — Jacek @ 05:29

You’ll want the SOA (Start of Authority) record for a given domain name, and this is how you accomplish it using the universally available nslookup command line tool:

command line> nslookup
> set querytype=soa
> stackoverflow.com
Server:         217.30.180.230
Address:        217.30.180.230#53

Non-authoritative answer:
stackoverflow.com
        origin = ns51.domaincontrol.com # ("primary name server" on Windows)
        mail addr = dns.jomax.net       # ("responsible mail addr" on Windows)
        serial = 2008041300
        refresh = 28800
        retry = 7200
        expire = 604800
        minimum = 86400
Authoritative answers can be found from:
stackoverflow.com       nameserver = ns52.domaincontrol.com.
stackoverflow.com       nameserver = ns51.domaincontrol.com.

source: http://stackoverflow.com/questions/38021/how-do-i-find-the-authoritative-name-server-for-a-domain-name 

24 lipca 2015

linux route

Zaszufladkowany do: Linux — Tagi: — Jacek @ 14:57

ifconfig eth0 down

iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -X chain – usnięcie łańcucha
iptables -F

route add default gw 192.168.4.254 eth1
route add -net 192.168.4.0 netmask 255.255.255.0 dev eth1

route del -net 192.168.4.0 netmask 255.255.255.0 gw 0.0.0.0 dev eth1
route del -net 192.168.4.0 netmask 255.255.255.0 gw 0.0.0.0 dev eth1
route del -net 0.0.0.0 netmask 0.0.0.0 gw 192.168.4.254 dev eth1
route del -net 192.168.4.0 netmask 255.255.255.0 gw 0.0.0.0 dev eth1

22 lipca 2015

firefox java plugin

Zaszufladkowany do: Linux — Tagi: — Jacek @ 17:05
sudo apt-get install icedtea-plugin

16 czerwca 2015

linux disable touchpad

Zaszufladkowany do: Linux — Tagi: — Jacek @ 08:07
xinput list
xinput set-prop 12 "Device Enabled" 0

29 kwietnia 2015

linux – image resize with aspect ratio

Zaszufladkowany do: Linux — Tagi: — Jacek @ 14:08

for i in *.png; do convert $i -resize 280×250\> zmienione/$i; done;

28 marca 2015

removie hidden files rm -rf

Zaszufladkowany do: Linux — Tagi: — Jacek @ 10:57

rm -rf .??*

11 grudnia 2014

ubuntu pakiety

Zaszufladkowany do: Linux — Tagi: — Jacek @ 14:02
sudo apt-get remove gnome-screensaver
sudo apt-get install gnome-core

-- skype instalka ---
sudo apt-file search libQtWebKit.so.4
libqtwebkit4: /usr/lib/x86_64-linux-gnu/libQtWebKit.so.4
libqtwebkit4: /usr/lib/x86_64-linux-gnu/libQtWebKit.so.4.10
libqtwebkit4: /usr/lib/x86_64-linux-gnu/libQtWebKit.so.4.10.2

sudo apt-get install libqtwebkit4:i386

3 grudnia 2014

php4 mod_php4.c

Zaszufladkowany do: Linux — Tagi: — Jacek @ 18:33

LoadModule php4_module /usr/lib/apache/1.3/libphp4.so
Addmodule mod_php4.c

2 grudnia 2014

Ubuntu – DNS

Zaszufladkowany do: Linux — Tagi: — Jacek @ 12:09

# /etc/nsswitch.conf
#
# Example configuration of GNU Name Service Switch functionality.
# If you have the `glibc-doc-reference’ and `info’ packages installed, try:
# `info libc “Name Service Switch”‘ for information about this file.

passwd:         compat
group:          compat
shadow:         compat

hosts:          files dns [NOTFOUND=return] mdns4_minimal mdns4
networks:       files

protocols:      db files
services:       db files
ethers:         db files
rpc:            db files

netgroup:       nis

cat /etc/resolvconf/resolv.conf.d/head
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND — YOUR CHANGES WILL BE OVERWRITTEN
nameserver 192.168.0.150
nameserver 192.168.0.151

25 listopada 2014

Linux NTP server installtion

Zaszufladkowany do: Linux — Tagi: — Jacek @ 17:58

http://www.thegeekstuff.com/2014/06/linux-ntp-server-client/

8 października 2014

dd i inne cuda

Zaszufladkowany do: Linux — Tagi: — Jacek @ 15:45
dd if=/dev/sr0 of=myCD.iso bs=2048 conv=noerror,sync
Creates an ISO disk image from a CD-ROM; in some cases the created ISO image may not be the same as the one which was used to burn the CD-ROM.[5]
dd if=/dev/sda2 of=/dev/sdb2 bs=4096 conv=noerror
Clones one partition to another.
dd if=/dev/ad0 of=/dev/ad1 bs=1M conv=noerror
Clones a hard disk “ad0″ to “ad1″

dd if=/dev/mapper/vgraid10-lvroot of=/dev/hdc2 bs=4096 conv=noerror

źródło: http://en.wikipedia.org/wiki/Dd_(Unix)

Linux switch console on OVM (konsola)

Zaszufladkowany do: Linux — Tagi: — Jacek @ 15:40

ALT+F1
ALT+F2

30 września 2014

mounting LVM volumes

Zaszufladkowany do: Linux — Tagi: — Jacek @ 19:07

SOURCE: http://pissedoffadmins.com/os/mount-unknown-filesystem-type-lvm2_member.html

mount: unknown filesystem type ‘LVM2_member’

i foobar’d a fedora 4 machine a couple of days ago and when i went to mount the disk into another machine i get this beautiful error:

mount: unknown filesystem type 'LVM2_member'

here was the syntax used:

termcb:~ # mount /dev/hda2 /mnt/old/
mount: unknown filesystem type 'LVM2_member'

and here was the drive :

termcb:~ # fdisk -l

Disk /dev/hda: 30.0 GB, 30005821440 bytes
255 heads, 63 sectors/track, 3648 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 13 104391 83 Linux
/dev/hda2 14 3648 29198137+ 8e Linux LVM

so using lvm2 tools, we do a disk scan:

termcb:~ # lvmdiskscan
/dev/ram0 [ 62.50 MB]
/dev/ram1 [ 62.50 MB]
/dev/hda1 [ 101.94 MB]
/dev/sda1 [ 39.19 MB]
/dev/ram2 [ 62.50 MB]
/dev/hda2 [ 27.85 GB] LVM physical volume
/dev/sda2 [ 2.01 GB]
/dev/ram3 [ 62.50 MB]
/dev/sda3 [ 60.00 GB]
/dev/ram4 [ 62.50 MB]
/dev/sda4 [ 86.96 GB]
/dev/ram5 [ 62.50 MB]
/dev/ram6 [ 62.50 MB]
/dev/ram7 [ 62.50 MB]
/dev/ram8 [ 62.50 MB]
/dev/ram9 [ 62.50 MB]
/dev/ram10 [ 62.50 MB]
/dev/ram11 [ 62.50 MB]
/dev/ram12 [ 62.50 MB]
/dev/ram13 [ 62.50 MB]
/dev/ram14 [ 62.50 MB]
/dev/ram15 [ 62.50 MB]
0 disks
21 partitions
0 LVM physical volume whole disks
1 LVM physical volume

then we do a lvdisplay so we can get the LV Name and VG Name:

termcb:~ # lvdisplay
--- Logical volume ---
LV Name /dev/VolGroup00/LogVol00
VG Name VolGroup00
LV UUID WBjpH6-Jezl-aI1z-XVSp-WzvW-qTDi-c1jkUv
LV Write Access read/write
LV Status NOT available
LV Size 26.06 GB
Current LE 834
Segments 1
Allocation inherit
Read ahead sectors 0

--- Logical volume ---
LV Name /dev/VolGroup00/LogVol01
VG Name VolGroup00
LV UUID Zykaw3-WBHU-oink-38W9-KylN-7u5j-PKx8qT
LV Write Access read/write
LV Status NOT available
LV Size 1.75 GB
Current LE 56
Segments 1
Allocation inherit
Read ahead sectors 0

and also a vgdisplay to make sure it was the right drive:

termcb:~ # vgdisplay
--- Volume group ---
VG Name VolGroup00
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 3
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 2
Open LV 0
Max PV 0
Cur PV 1
Act PV 1
VG Size 27.84 GB
PE Size 32.00 MB
Total PE 891
Alloc PE / Size 890 / 27.81 GB
Free PE / Size 1 / 32.00 MB
VG UUID ryYRi4-mXOd-XFaW-4xnR-h1cl-hphh-5QQnlM

so at this point i re-tried to mount but using the VG Name:

termcb:~ # mount /dev/VolGroup00/LogVol00 /mnt/old/
mount: special device /dev/VolGroup00/LogVol00 does not exist

still failure

so i did an lvscan next to see what the status of the lv drive is:

termcb:~ # lvscan
inactive '/dev/VolGroup00/LogVol00' [26.06 GB] inherit
inactive '/dev/VolGroup00/LogVol01' [1.75 GB] inherit

fuck…. still inactive
thats when i stumbled across this post :
http://www.fedoraforum.org/forum/archiv … 64964.html

now the rest was pretty self explanatory:

modprobe dm-mod

vgchange -ay

termcb:~ # lvscan
ACTIVE '/dev/VolGroup00/LogVol00' [26.06 GB] inherit
ACTIVE '/dev/VolGroup00/LogVol01' [1.75 GB] inherit

mount /dev/VolGroup00/LogVol00 /mount/point

Success!!

The following command adds the physical volume /dev/sdf1 to the volume group vg1.
# vgextend vg1 /dev/sdf1

(https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Logical_Volume_Manager_Administration/VG_grow.html)

http://www.rootusers.com/how-to-increase-the-size-of-a-linux-lvm-by-adding-a-new-disk/

http://www.howtogeek.com/howto/40702/how-to-manage-and-use-lvm-logical-volume-management-in-ubuntu/

24 września 2014

Ubuntu RPMs

Zaszufladkowany do: Linux — Tagi: — Jacek @ 14:16

sudo apt-get install alien
sudo alien -k nazwa_paczki.rpm  przekonwertorowanie paczki rpm na deb.
sudo alien -i nazwa paczki.rpm  bezpośrednia instalacja z paczki rpm.

18 sierpnia 2014

ubuntu start with (uruchom z)

Zaszufladkowany do: Linux — Tagi: — Jacek @ 09:07

To add any program in the list of default list of open with applications, open a terminal and use the following command:

sudo gedit /usr/share/applications/XXX.desktop

Please note two things. In XXX.desktop, XXX is the name of your application. And then use of gedit. You can use any other editor. I used Vim. If you use Gedit, it will dispaly some warning messages in the terminal but will open the file in a GUI.

In this desktop file, look for a line that looks like this:

Exec=XXX

If you have something like this, replace this line with:

Exec=XXX %F

18 czerwca 2014

libXtst.so.6 cannot open shared object file error during Oracle Installation

Zaszufladkowany do: Linux — Tagi: — Jacek @ 17:17

sudo apt-get install libxtst-dev:i386

12 czerwca 2014

ubuntu – pakiety

Zaszufladkowany do: Linux — Tagi: — Jacek @ 09:19

instalacja
dpkg -i pakiet.deb
usunięcie
dpkg -r pakiet.deb
rekonfiguracja
dpkg -reconfigure pakiet.deb

« Nowsze wpisyStarsze wpisy »

Strona startowa: www.jaceksen.pl