Долго меня мучила проблема скачивания файлов с русским именем через wget. И вот на просторах интернета я нашёл решение. wget --restrict-file-names=nocontrol За подробностями в man wget Спасибо mydebianblog.blogspot.ru Взято на память отсюда http://mydebianblog.blogspot.ru/2007/09/wget.html
Таких блогов миллиарды, и что бы не рыскать в гугле, и вспоминать как там было, я для себя пишу маленькие комментарии.
среда, 9 октября 2013 г.
Wget и русский язык
пятница, 28 июня 2013 г.
sed удаление пробелов и табуляций
$ sed -i 's/^[ \t]*//;s/[ \t]*$//' file_name.txt
Удалит все пробелы + табуляции в начале и в конце строки, оставив только содержимое.
Удалит все пробелы + табуляции в начале и в конце строки, оставив только содержимое.
понедельник, 10 декабря 2012 г.
Восстанавливаем ORACLE из RMAN
[oracle@isvpdb ~]$ rman target /
Recovery Manager: Release 11.2.0.2.0 - Production on Mon Dec 10 17:16:55 2012
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
connected to target database (not started)
RMAN> startup nomount;
Oracle instance started
Total System Global Area 1603411968 bytes
Fixed Size 2226912 bytes
Variable Size 419431712 bytes
Database Buffers 1174405120 bytes
Redo Buffers 7348224 bytes
RMAN> restore controlfile from '/home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf';
Starting restore at 10-DEC-12
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=156 device type=DISK
channel ORA_DISK_1: copied control file copy
output file name=/u01/app/oracle/oradata/wpsbaza/control01.ctl
output file name=/u01/app/oracle/fast_recovery_area/wpsbaza/control02.ctl
Finished restore at 10-DEC-12
RMAN> alter database mount;
database mounted
released channel: ORA_DISK_1
RMAN> CATALOG START WITH '/home/oracle/20121206/';
Starting implicit crosscheck backup at 10-DEC-12
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=156 device type=DISK
Crosschecked 200 objects
Finished implicit crosscheck backup at 10-DEC-12
Starting implicit crosscheck copy at 10-DEC-12
using channel ORA_DISK_1
Crosschecked 400 objects
Finished implicit crosscheck copy at 10-DEC-12
searching for all files in the recovery area
cataloging files...
no files cataloged
searching for all files that match the pattern /home/oracle/20121206/
List of Files Unknown to the Database
=====================================
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_icns5lk5_1_1
File Name: /home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
File Name: /home/oracle/20121206/al_WPSBAZA_20121206_idns5lkg_1_1
Do you really want to catalog the above files (enter YES or NO)? yes
cataloging files...
cataloging done
List of Cataloged Files
=======================
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_icns5lk5_1_1
File Name: /home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
File Name: /home/oracle/20121206/al_WPSBAZA_20121206_idns5lkg_1_1
RMAN> restore database;
Starting restore at 10-DEC-12
using channel ORA_DISK_1
channel ORA_DISK_1: starting datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
channel ORA_DISK_1: restoring datafile 00001 to /u01/app/oracle/oradata/wpsbaza/system01.dbf
channel ORA_DISK_1: restoring datafile 00002 to /u01/app/oracle/oradata/wpsbaza/sysaux01.dbf
channel ORA_DISK_1: restoring datafile 00003 to /u01/app/oracle/oradata/wpsbaza/undotbs01.dbf
channel ORA_DISK_1: restoring datafile 00004 to /u01/app/oracle/oradata/wpsbaza/users01.dbf
channel ORA_DISK_1: restoring datafile 00005 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLFQ32_01.dbf
channel ORA_DISK_1: restoring datafile 00006 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLNF32_01.dbf
channel ORA_DISK_1: restoring datafile 00007 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMSFQ04_01.dbf
channel ORA_DISK_1: restoring datafile 00008 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMVFQ04_01.dbf
channel ORA_DISK_1: restoring datafile 00009 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_CMBINV04_01.dbf
channel ORA_DISK_1: restoring datafile 00010 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLSNDX_01.dbf
channel ORA_DISK_1: reading from backup piece /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
channel ORA_DISK_1: piece handle=/home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1 tag=TAG20121206T064617
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:25
Finished restore at 10-DEC-12
RMAN> recover database; (зафейлилась)
Starting recover at 10-DEC-12
using channel ORA_DISK_1
starting media recovery
unable to find archived log
archived log thread=1 sequence=1003
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 12/10/2012 17:23:58
RMAN-06054: media recovery requesting unknown archived log for thread 1 with sequence 1003 and starting SCN of 33832035
RMAN> recover database until sequence 1003;
RMAN> alter database open resetlogs;
RMAN> quit;
Recovery Manager: Release 11.2.0.2.0 - Production on Mon Dec 10 17:16:55 2012
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
connected to target database (not started)
RMAN> startup nomount;
Oracle instance started
Total System Global Area 1603411968 bytes
Fixed Size 2226912 bytes
Variable Size 419431712 bytes
Database Buffers 1174405120 bytes
Redo Buffers 7348224 bytes
RMAN> restore controlfile from '/home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf';
Starting restore at 10-DEC-12
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=156 device type=DISK
channel ORA_DISK_1: copied control file copy
output file name=/u01/app/oracle/oradata/wpsbaza/control01.ctl
output file name=/u01/app/oracle/fast_recovery_area/wpsbaza/control02.ctl
Finished restore at 10-DEC-12
RMAN> alter database mount;
database mounted
released channel: ORA_DISK_1
RMAN> CATALOG START WITH '/home/oracle/20121206/';
Starting implicit crosscheck backup at 10-DEC-12
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=156 device type=DISK
Crosschecked 200 objects
Finished implicit crosscheck backup at 10-DEC-12
Starting implicit crosscheck copy at 10-DEC-12
using channel ORA_DISK_1
Crosschecked 400 objects
Finished implicit crosscheck copy at 10-DEC-12
searching for all files in the recovery area
cataloging files...
no files cataloged
searching for all files that match the pattern /home/oracle/20121206/
List of Files Unknown to the Database
=====================================
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_icns5lk5_1_1
File Name: /home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
File Name: /home/oracle/20121206/al_WPSBAZA_20121206_idns5lkg_1_1
Do you really want to catalog the above files (enter YES or NO)? yes
cataloging files...
cataloging done
List of Cataloged Files
=======================
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_icns5lk5_1_1
File Name: /home/oracle/20121206/cl_WPSBAZA_20121206_cf_D-WPSBAZA_id-3655181439_ians5lhf
File Name: /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
File Name: /home/oracle/20121206/al_WPSBAZA_20121206_idns5lkg_1_1
RMAN> restore database;
Starting restore at 10-DEC-12
using channel ORA_DISK_1
channel ORA_DISK_1: starting datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
channel ORA_DISK_1: restoring datafile 00001 to /u01/app/oracle/oradata/wpsbaza/system01.dbf
channel ORA_DISK_1: restoring datafile 00002 to /u01/app/oracle/oradata/wpsbaza/sysaux01.dbf
channel ORA_DISK_1: restoring datafile 00003 to /u01/app/oracle/oradata/wpsbaza/undotbs01.dbf
channel ORA_DISK_1: restoring datafile 00004 to /u01/app/oracle/oradata/wpsbaza/users01.dbf
channel ORA_DISK_1: restoring datafile 00005 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLFQ32_01.dbf
channel ORA_DISK_1: restoring datafile 00006 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLNF32_01.dbf
channel ORA_DISK_1: restoring datafile 00007 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMSFQ04_01.dbf
channel ORA_DISK_1: restoring datafile 00008 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMVFQ04_01.dbf
channel ORA_DISK_1: restoring datafile 00009 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_CMBINV04_01.dbf
channel ORA_DISK_1: restoring datafile 00010 to /u01/app/oracle/oradata/wpsbaza/data/wpsbaza_ICMLSNDX_01.dbf
channel ORA_DISK_1: reading from backup piece /home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1
channel ORA_DISK_1: piece handle=/home/oracle/20121206/bk_WPSBAZA_20121206_ibns5lhq_1_1 tag=TAG20121206T064617
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:25
Finished restore at 10-DEC-12
RMAN> recover database; (зафейлилась)
Starting recover at 10-DEC-12
using channel ORA_DISK_1
starting media recovery
unable to find archived log
archived log thread=1 sequence=1003
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 12/10/2012 17:23:58
RMAN-06054: media recovery requesting unknown archived log for thread 1 with sequence 1003 and starting SCN of 33832035
RMAN> recover database until sequence 1003;
RMAN> alter database open resetlogs;
RMAN> quit;
четверг, 25 октября 2012 г.
Gedit-gmate вылетает.
Поставил себе Gedit-gmate подробное описание есть на habr.ru
Столкнулся с проблемой вылетания gmate сразу после запуска.
Причем если запускать gmate из терминала то выхлопа никого не было,
а gedit выплёвывал
$ gedit
** (gedit:3889): WARNING **: Could not load theme icon gtk-home: Icon
'gtk-home' not present in theme
** (gedit:3889): CRITICAL **: gedit_document_load: assertion
`gedit_utils_is_valid_location (location)' failed
Exception TypeError: "Couldn't find conversion for foreign struct
'cairo.Context'" in 'garbage collection' ignored
Fatal Python error: unexpected exception during garbage collection
Aborted
решил проблему установкой python-gi-cairo python-cairo-dev
$ sudo aptitude install python-gi-cairo python-cairo-dev -y
Столкнулся с проблемой вылетания gmate сразу после запуска.
Причем если запускать gmate из терминала то выхлопа никого не было,
а gedit выплёвывал
$ gedit
** (gedit:3889): WARNING **: Could not load theme icon gtk-home: Icon
'gtk-home' not present in theme
** (gedit:3889): CRITICAL **: gedit_document_load: assertion
`gedit_utils_is_valid_location (location)' failed
Exception TypeError: "Couldn't find conversion for foreign struct
'cairo.Context'" in 'garbage collection' ignored
Fatal Python error: unexpected exception during garbage collection
Aborted
решил проблему установкой python-gi-cairo python-cairo-dev
$ sudo aptitude install python-gi-cairo python-cairo-dev -y
пятница, 12 октября 2012 г.
[Решено] Нет звука в Ubuntu 12.04 ALC269VB
Всем здравствуйте, столкнулся с проблемой отсутствия звука на ноутбуке , устанавливал ubuntu minimal, X ставил отдельно, i3wm рулит.
Что имеем:
NoteBook: Samsung 305U1A
Card: HDA ATI SB
Chip: Realtek ALC269VB
Soft: aplay, mocp, flashplayer etc.
Первым делом я установил все пакеты которые мне нужны для звука.
sudo aptitude install -y alsa-base alsa-oss alsa-tools alsa-utils alsaplayer-alsa alsaplayer-common alsaplayer-daemon libalsaplayer-dev libalsaplayer0 moc moc-ffmpeg-plugin
После я добавил своего пользователя в группу audio
sudo adduser myname audio
cat /proc/asound/cards показывал что у меня две звуковые карты
0 [Generic]: HDA-Intel - HD-Audio Generic HD-Audio Generic at 0xfeb44000
1 [SB]: HDA-Intel - HDA ATI SB HDA ATI SB at 0xfeb40000
Через alsamixer я выяснил что мне нужна карта под номером 1
Отредактировал ~/.asoundrc
pcm.!default {
type hw
card 1
}
ctl.!default {
type hw
card 1
}
После всё заработало.
Что имеем:
NoteBook: Samsung 305U1A
Card: HDA ATI SB
Chip: Realtek ALC269VB
Soft: aplay, mocp, flashplayer etc.
Первым делом я установил все пакеты которые мне нужны для звука.
sudo aptitude install -y alsa-base alsa-oss alsa-tools alsa-utils alsaplayer-alsa alsaplayer-common alsaplayer-daemon libalsaplayer-dev libalsaplayer0 moc moc-ffmpeg-plugin
После я добавил своего пользователя в группу audio
sudo adduser myname audio
cat /proc/asound/cards показывал что у меня две звуковые карты
0 [Generic]: HDA-Intel - HD-Audio Generic HD-Audio Generic at 0xfeb44000
1 [SB]: HDA-Intel - HDA ATI SB HDA ATI SB at 0xfeb40000
Через alsamixer я выяснил что мне нужна карта под номером 1
Отредактировал ~/.asoundrc
pcm.!default {
type hw
card 1
}
ctl.!default {
type hw
card 1
}
После всё заработало.
среда, 26 сентября 2012 г.
wicd wifi wpa2 bad password
Что имеем:
HW: Samsung 305U1A
WiFi Чип: BCM4313 802.11
Network-Manager: Wicd-deamon
При попытке подключится к wifi через wicd я постоянно видел сообщение, о
том что не правильный пароль и т.д.
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: Putting interface down
2012/09/20 19:02:46 :: Releasing DHCP leases...
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: Setting false IP...
2012/09/20 19:02:46 :: Stopping wpa_supplicant
2012/09/20 19:02:46 :: Flushing the routing table...
2012/09/20 19:02:46 :: Putting interface up...
2012/09/20 19:02:48 :: Attempting to authenticate...
2012/09/20 19:03:24 :: wpa_supplicant authentication may have failed.
2012/09/20 19:03:24 :: connect result is failed
2012/09/20 19:03:24 :: exiting connection thread
2012/09/20 19:03:24 :: Sending connection attempt result bad_pass
2012/09/20 19:03:24 :: attempting to set hostname with dhclient
2012/09/20 19:03:24 :: using dhcpcd or another supported client may work better
2012/09/20 19:03:24 :: attempting to set hostname with dhclient
2012/09/20 19:03:24 :: using dhcpcd or another supported client may work better
2012/09/20 19:03:50 :: Daemon going down, killing wicd-monitor...
Проблема решилась установкой пакета bcmwl-kernel-source
sudo aptitude install bcmwl-kernel-source -y
После этого wlan0 переименовался в eth1, я изменил список устройств в wicd-gtk и всё заработало.
HW: Samsung 305U1A
WiFi Чип: BCM4313 802.11
Network-Manager: Wicd-deamon
При попытке подключится к wifi через wicd я постоянно видел сообщение, о
том что не правильный пароль и т.д.
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: Putting interface down
2012/09/20 19:02:46 :: Releasing DHCP leases...
2012/09/20 19:02:46 :: attempting to set hostname with dhclient
2012/09/20 19:02:46 :: using dhcpcd or another supported client may work better
2012/09/20 19:02:46 :: Setting false IP...
2012/09/20 19:02:46 :: Stopping wpa_supplicant
2012/09/20 19:02:46 :: Flushing the routing table...
2012/09/20 19:02:46 :: Putting interface up...
2012/09/20 19:02:48 :: Attempting to authenticate...
2012/09/20 19:03:24 :: wpa_supplicant authentication may have failed.
2012/09/20 19:03:24 :: connect result is failed
2012/09/20 19:03:24 :: exiting connection thread
2012/09/20 19:03:24 :: Sending connection attempt result bad_pass
2012/09/20 19:03:24 :: attempting to set hostname with dhclient
2012/09/20 19:03:24 :: using dhcpcd or another supported client may work better
2012/09/20 19:03:24 :: attempting to set hostname with dhclient
2012/09/20 19:03:24 :: using dhcpcd or another supported client may work better
2012/09/20 19:03:50 :: Daemon going down, killing wicd-monitor...
Проблема решилась установкой пакета bcmwl-kernel-source
sudo aptitude install bcmwl-kernel-source -y
После этого wlan0 переименовался в eth1, я изменил список устройств в wicd-gtk и всё заработало.
четверг, 7 июня 2012 г.
IHS7 and Centos6
1) http://www-304.ibm.com/support/docview.wss?uid=swg27020956
wget ftp://public.dhe.ibm.com/software/websphere/appserv/support/osprecheck/was70/httpserver/amd64/maintenance.xml
wget ftp://public.dhe.ibm.com/software/websphere/appserv/support/osprecheck/was70/plugins/amd64/maintenance.xml
2) http://portal2portal.blogspot.com/2011/12/installing-ibm-http-server-7-on-centos.html
wget ftp://public.dhe.ibm.com/software/websphere/appserv/support/osprecheck/was70/httpserver/amd64/maintenance.xml
wget ftp://public.dhe.ibm.com/software/websphere/appserv/support/osprecheck/was70/plugins/amd64/maintenance.xml
2) http://portal2portal.blogspot.com/2011/12/installing-ibm-http-server-7-on-centos.html
yum install ld-linux.so.2
yum install libgcc_s.so.1
3) yum install compat-libstdc++-296.i686 compat-libstdc++-33.i686 compat-libstdc++-33.x86_64 libstdc++.i686 libstdc++.x86_64 libstdc++-devel.i686 libstdc++-devel.x86_64 compat-libstdc++-33 compat-db libXp libXmu libXtst pam libXft -y
yum install libgcc_s.so.1
3) yum install compat-libstdc++-296.i686 compat-libstdc++-33.i686 compat-libstdc++-33.x86_64 libstdc++.i686 libstdc++.x86_64 libstdc++-devel.i686 libstdc++-devel.x86_64 compat-libstdc++-33 compat-db libXp libXmu libXtst pam libXft -y
Подписаться на:
Сообщения (Atom)