Temmuz 30, 2013 § § Kalıcı bağlantı
Dosyamızı oluşturalım:
printf 'testing\012\011\011testing\014\010\012more testing\012\011\000\013\000even more testing\012\011\011\011\012' > /tmp/testing.txt
Dosyanın içeriği
cat /tmp/testing.txt
testing
testing
more testing
even more testing
Tab karakterini “^I” olarak görmek için
cat -T /tmp/testing.txt
testing
^I^Itesting
more testing
^I
even more testing
^I^I^I
Satır sonlarını “$” olarak görmek
cat -E /tmp/testing.txt
testing$
testing
$
more testing$
even more testing$
$
Bütün görünmeyen karakterleri görmek için
cat -A /tmp/testing.txt
testing$
^I^Itesting^L^H$
more testing$
^I^@^K^@even more testing$
^I^I^I$
Temmuz 30, 2013 § § Kalıcı bağlantı
# Create file
$ cat > /tmp/temp_file_name.txt
some content
more content
and even more content
<Ctrl-D>
# View file content
$ cat /tmp/temp_file_name.txt
some content
more content
and even more content
# Append to file
$ cat >> /tmp/temp_file_name.txt
append content
append more content
append even more content
<Ctrl-D>
# View file content
$ cat /tmp/temp_file_name.txt
some content
more content
and even more content
append content
append more content
append even more content
Temmuz 30, 2013 § § Kalıcı bağlantı
cat /proc/version
dmesg | grep "Linux version"
lsb_release -a
LSB Version: :core-4.0-ia32:core-4.0-noarch
Distributor ID: Fedora
Description: Fedora release 14 (Laughlin)
Release: 14
Codename: Laughlin
uname -a
Temmuz 30, 2013 § § Kalıcı bağlantı
İlgili “vim-enhanced” paketini kuralım:
yum install vim-enhanced
/etc/profile veya /etc/profile.d/vi-vim.sh veya kullanıcının ~/.bashrc dosyasına alias ekleyelim.
vi .bashrc
...
# User specific aliases and functions
alias vi=vim
vimrc dosyasını düzenleyelim
vi /etc/vimrc
...
syntax on
İşte sonuç:

Not: Vi içinde “:syntax on” ile “:syntax off” bu özellik açılıp kapanabilir.
Temmuz 30, 2013 § § Kalıcı bağlantı
Bütün yum işlerini listele
[root ~]> yum history
### OR ###
[root ~]> yum history list
Loaded plugins: dellsysidplugin2, fastestmirror, refresh-packagekit
ID | Login user | Date and time | Action(s) | Altered
-------------------------------------------------------------------------------
45 | System <unset> | 2010-01-18 09:57 | I, U | 21
44 | User <username> | 2010-01-14 15:31 | Install | 1
43 | System <unset> | 2010-01-14 08:13 | Update | 19
42 | System <unset> | 2010-01-13 10:39 | I, U | 40
41 | System <unset> | 2010-01-11 07:59 | Update | 16
40 | System <unset> | 2010-01-08 07:58 | Update | 38
39 | System <unset> | 2010-01-07 08:39 | I, O, U | 39
38 | System <unset> | 2010-01-05 08:23 | O, U | 18
37 | User <username> | 2010-01-04 15:43 | Install | 1
36 | System <unset> | 2010-01-04 07:56 | Update | 66
35 | User <username> | 2009-12-30 10:07 | Install | 2
34 | User <username> | 2009-12-30 10:01 | Update | 15
33 | User <username> | 2009-12-30 08:14 | Install | 13
32 | System <unset> | 2009-12-29 07:52 | I, U | 26
31 | System <unset> | 2009-12-28 08:31 | E, I, U | 66
30 | System <unset> | 2009-12-23 12:11 | Update | 7
29 | System <unset> | 2009-12-22 13:59 | Update | 36
28 | User <username> | 2009-12-21 13:21 | Install | 1
27 | System <unset> | 2009-12-18 14:59 | Update | 56
26 | User <username> | 2009-12-18 08:46 | Install | 1
history list
ID ile history bilgisine ulaşalım:
[root ~]> yum history info 2
Loaded plugins: dellsysidplugin2, fastestmirror, refresh-packagekit
Transaction ID : 2
Begin time : Tue Jan 19 15:10:13 2010
Begin rpmdb : 2431:fe4c2c846fd45c9125fb8ab27542a27b22e0d3df
End time : 15:10:27 2010 (14 seconds)
End rpmdb : 2430:2eeb12b0b0f2ef3fcb31b4447b439e76e92e3866
User : User <username>
Return-Code : Success
Transaction performed with:
Installed rpm-4.7.2-1.fc12.i686
Installed yum-3.2.25-1.fc12.noarch
Installed yum-plugin-fastestmirror-1.1.24-2.fc12.noarch
Packages Altered:
Erase arora-0.10.2-2.fc12.i686
history info
ID ile redo ve undo yapmak
[root ~]> yum history repeat 2
Loaded plugins: dellsysidplugin2, fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
* fedora: mirror.cogentco.com
* livna: rpm.livna.org
[...]
Repeating transaction 2, from Tue Jan 19 15:10:13 2010
Erase arora-0.10.2-2.fc12.i686
No package matched to remove
history repeat
[root ~]> yum history undo 2
Loaded plugins: dellsysidplugin2, fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
[...]
Undoing transaction 2, from Tue Jan 19 15:10:13 2010
Erase arora-0.10.2-2.fc12.i686
Resolving Dependencies
--> Running transaction check
---> Package arora.i686 0:0.10.2-2.fc12 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
=================================================================================================================================================================================
Package Arch Version Repository Size
=================================================================================================================================================================================
Installing:
arora i686 0.10.2-2.fc12 updates 1.1 M
Transaction Summary
=================================================================================================================================================================================
Install 1 Package(s)
Upgrade 0 Package(s)
Total download size: 1.1 M
Is this ok [y/N]: y
Downloading Packages:
arora-0.10.2-2.fc12.i686.rpm | 1.1 MB 00:00
[...]
Running Transaction
Installing : arora-0.10.2-2.fc12.i686 1/1
Installed:
arora.i686 0:0.10.2-2.fc12
Complete!
[root ~]> yum history redo 2
Loaded plugins: dellsysidplugin2, fastestmirror, refresh-packagekit
[...]
Repeating transaction 2, from Tue Jan 19 15:10:13 2010
Erase arora-0.10.2-2.fc12.i686
Resolving Dependencies
--> Running transaction check
---> Package arora.i686 0:0.10.2-2.fc12 set to be erased
--> Finished Dependency Resolution
Dependencies Resolved
=================================================================================================================================================================================
Package Arch Version Repository Size
=================================================================================================================================================================================
Removing:
arora i686 0.10.2-2.fc12 installed 3.7 M
Transaction Summary
=================================================================================================================================================================================
Remove 1 Package(s)
Reinstall 0 Package(s)
Downgrade 0 Package(s)
Is this ok [y/N]: y
[...]
Running Transaction
Erasing : arora-0.10.2-2.fc12.i686 1/1
Removed:
arora.i686 0:0.10.2-2.fc12
Complete!
Temmuz 30, 2013 § § Kalıcı bağlantı
Repoları listeleyelim
$ yum repolist
Loaded plugins: dellsysidplugin2, refresh-packagekit
repo id repo name status
adobe-linux-i386 Adobe Systems Incorporated enabled: 17
fedora Fedora 12 - i386 enabled: 15,366
google Google - i386 enabled: 4
livna rpm.livna.org for 12 - i386 enabled: 3
rpmfusion-free RPM Fusion for Fedora 12 - Free enabled: 383
rpmfusion-free-updates RPM Fusion for Fedora 12 - Free - Updates enabled: 551
rpmfusion-nonfree RPM Fusion for Fedora 12 - Nonfree enabled: 124
rpmfusion-nonfree-updates RPM Fusion for Fedora 12 - Nonfree - Updates enabled: 228
updates Fedora 12 - i386 - Updates enabled: 4,587
repolist: 21,263
Google reposundan paket kuralım
$ yum --disablerepo="*" --enablerepo="google" list available
Loaded plugins: dellsysidplugin2, refresh-packagekit
Available Packages
google-chrome-beta.i386 5.0.307.9-39052 google
google-chrome-unstable.i386 5.0.322.2-38810 google
google-desktop-linux.i386 1.2.0-0088 google
picasa.i386
Temmuz 30, 2013 § § Kalıcı bağlantı
Bash autocomlete paketini kuralım.
yum install bash-completion
Şimdi kullandığımız konsolu değiştirelim ve deneme yapalım:
[root ~]$ yum s[TAB][TAB]
search shell
[root ~]$ yum install fire[TAB][TAB]
firebird-classic.i686 firebird.i686 firecontrol.i686
firebird-devel.i686 firebird-libfbembed.i686 firehol.noarch
firebird-doc.i686 firebird-superserver.i686 firewalk.i686
[root ~]$ yum remove ge[TAB][TAB]
gedit.i686 geoclue-devel.i686 geronimo-jms.noarch gettext.i686
gegl.i686 geoclue.i686 geronimo-jta.noarch gettext-libs.i686
genisoimage.i686 GeoIP.i686 gettext-devel.i686
Güzel değil mi??
Temmuz 30, 2013 § § Kalıcı bağlantı
Paketlerin eski sürümlerini kullanmak gerektiğinde “yum downgrade” kullanılabilir.
Bu işlem ile paket bağımlılıkları otomatik olarak çözülmez.
Bağımlılıkları teker teker downgrade etmek gerekebilir.
Paket bağımlılığı yokken:
yum downgrade hunspell-mr.noarch
Setting up Downgrade Process
Resolving Dependencies
--> Running transaction check
---> Package hunspell-mr.noarch 0:20060920-5.fc13 set to be downgraded
---> Package hunspell-mr.noarch 0:20060920-6.fc14 set to be erased
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Downgrading:
hunspell-mr noarch 20060920-5.fc13 fedora 62 k
Transaction Summary
================================================================================
Downgrade 1 Package(s)
Total download size: 62 k
Is this ok [y/N]: y
Downloading Packages:
hunspell-mr-20060920-5.fc13.noarch.rpm | 62 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : hunspell-mr-20060920-5.fc13.noarch 1/2
Cleanup : hunspell-mr-20060920-6.fc14.noarch 2/2
Removed:
hunspell-mr.noarch 0:20060920-6.fc14
Installed:
hunspell-mr.noarch 0:20060920-5.fc13
Complete!
Bağımlık varsa:
yum downgrade sqlite
Setting up Downgrade Process
Resolving Dependencies
--> Running transaction check
---> Package sqlite.i686 0:3.6.22-1.fc13 set to be downgraded
---> Package sqlite.i686 0:3.6.23-1.fc14 set to be erased
--> Finished Dependency Resolution
Error: Package: sqlite-devel-3.6.23-1.fc14.i686 (@rawhide/12)
Requires: sqlite = 3.6.23-1.fc14
Removing: sqlite-3.6.23-1.fc14.i686 (@rawhide/12)
sqlite = 3.6.23-1.fc14
Downgraded By: sqlite-3.6.22-1.fc13.i686 (fedora)
sqlite = 3.6.22-1.fc13
You could try using --skip-broken to work around the problem
Önce bağımlılığı çözelim:
yum downgrade sqlite-devel sqlite
Setting up Downgrade Process
Resolving Dependencies
--> Running transaction check
---> Package sqlite.i686 0:3.6.22-1.fc13 set to be downgraded
---> Package sqlite.i686 0:3.6.23-1.fc14 set to be erased
---> Package sqlite-devel.i686 0:3.6.22-1.fc13 set to be downgraded
---> Package sqlite-devel.i686 0:3.6.23-1.fc14 set to be erased
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Downgrading:
sqlite i686 3.6.22-1.fc13 fedora 309 k
sqlite-devel i686 3.6.22-1.fc13 fedora 80 k
Transaction Summary
================================================================================
Downgrade 2 Package(s)
Total download size: 389 k
Is this ok [y/N]: y
Downloading Packages:
(1/2): sqlite-3.6.22-1.fc13.i686.rpm | 309 kB 00:00
(2/2): sqlite-devel-3.6.22-1.fc13.i686.rpm | 80 kB 00:00
--------------------------------------------------------------------------------
Total 438 kB/s | 389 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : sqlite-3.6.22-1.fc13.i686 1/4
Installing : sqlite-devel-3.6.22-1.fc13.i686 2/4
Cleanup : sqlite-devel-3.6.23-1.fc14.i686 3/4
Cleanup : sqlite-3.6.23-1.fc14.i686 4/4
Removed:
sqlite.i686 0:3.6.23-1.fc14 sqlite-devel.i686 0:3.6.23-1.fc14
Installed:
sqlite.i686 0:3.6.22-1.fc13 sqlite-devel.i686 0:3.6.22-1.fc13
Complete!
Temmuz 30, 2013 § § Kalıcı bağlantı
[fatih@localhost ~]$ cat 1.sh
function check_compression {
curl -I -H 'Accept-Encoding: gzip,deflate' $1 |grep "Content-Encoding"
}
check_compression http://www.linuxwiki.net
[fatih@localhost ~]$ bash 1.sh
Temmuz 30, 2013 § § Kalıcı bağlantı
Atrpms Repoyu ekleyelim
32-bit --> rpm -Uhv http://dl.atrpms.net/all/atrpms-repo-6-6.el6.i686.rpm
64-bit --> rpm -Uhv http://dl.atrpms.net/all/atrpms-repo-6-6.el6.x86_64.rpm
Macromedia Repoyu ekleyelim
32-bit --> rpm -Uhv http://linuxdownload.adobe.com/adobe-release/adobe-release-i386-1.0-1.noarch.rpm
64-bit --> rpm -Uhv http://linuxdownload.adobe.com/adobe-release/adobe-release-x86_64-1.0-1.noarch.rpm
Multimedya dosyalarını yükleyelim
yum install ffmpeg libdvdcss libdvdread libdvdnav libdvdplay lsdvd libquicktime mplayer mplayerplug-in gstreamer-plugins-ugly gstreamer-ffmpeg gstreamer-plugins-bad-free vlc
Flash desteğini ekleyelim
yum install flash-plugin