# Add new disk as a logical volume # Create partition fdisk -l fdisk /dev/sdb n-1-rtn-rtn # Create a physical volume pvcreate /dev/sdb1 pvdisplay # Create a virtual group VolGroup01 vgcreate VolGroup01 /dev/sdb1 # Get PE size from vgdisplay vgdisplay Total PE 4094 # Create a logical volume lvcreate -n vol01 -l 4094 VolGroup01 lvdisplay mkfs.ext3 /dev/VolGroup01/vol01 # Add to fstab vi /etc/fstab /dev/VolGroup01/vol01 /u01 ext3 defaults 0 0 mount /u01 ![]() |
Friday, 11 September 2009
Linux : add additonal disk as a logical volume
Posted by
Ook
at
07:11
0
comments
Labels: Linux
Thursday, 10 September 2009
BOXI : Restore to point in time with oracle
![]() |
Posted by
Ook
at
09:43
0
comments
Labels: Oracle
Oracle : Refresh the dataguard instance and re-enable
shudown immediate
Note
![]() |
Posted by
Ook
at
09:41
0
comments
Labels: Oracle
Wednesday, 9 September 2009
Oracle : 11GR2 - File Watchers
Trigger scheduler jobs when a glob-matched file is created in a directory ![]() |
Posted by
Ook
at
06:27
0
comments
Labels: Oracle
Oracle : 11GR2 - IGNORE_ROW_ON_DUPKEY_INDEX Hint
Silently ignore new rows that violate a single unique index.
Bulk operations? Multiple rows with same UK being inserted - which get in - arbitrary ? ![]() |
Posted by
Ook
at
04:20
0
comments
Labels: Oracle
Oracle : 11GR2 - Recursive subqueries for hierarchy traversal
Recursive Subquery Example =========================== WITH reports_to_101 (eid, emp_last, mgr_id, reportLevel) AS ( SELECT employee_id, last_name, manager_id, 0 reportLevel FROM employees WHERE employee_id = 101 UNION ALL SELECT e.employee_id, e.last_name, e.manager_id, reportLevel+1 FROM reports_to_101 r /* MAGIC IS HERE */ ,employees e WHERE r.eid = e.manager_id ) SELECT eid, emp_last, mgr_id, reportLevel FROM reports_to_101 ORDER BY reportLevel, eid; EID EMP_LAST MGR_ID REPORTLEVEL ---------- ------------------------- ---------- ----------- 101 Kochhar 100 0 108 Greenberg 101 1 200 Whalen 101 1 203 Mavris 101 1 204 Baer 101 1 205 Higgins 101 1 109 Faviet 108 2 110 Chen 108 2 111 Sciarra 108 2 112 Urman 108 2 113 Popp 108 2 206 Gietz 205 2 Ref ![]() |
Posted by
Ook
at
04:11
0
comments
Labels: Oracle
Oracle : 11GR2 - LISTAGG - the long missing string concatentation built-in
Finally LISTAGG Example =============== SELECT department_id "Dept.", LISTAGG(last_name, '; ') WITHIN GROUP (ORDER BY hire_date) "Employees" FROM employees GROUP BY department_id; Dept. Employees ------ ------------------------------------------------------------ 10 Whalen 20 Hartstein; Fay 30 Raphaely; Khoo; Tobias; Baida; Himuro; Colmenares 40 Mavris 50 Kaufling; Ladwig; Rajs; Sarchand; Bell; Mallin; Weiss; Davie s; Marlow; Bull; Everett; Fripp; Chung; Nayer; Dilly; Bissot ; Vollman; Stiles; Atkinson; Taylor; Seo; Fleaur; Matos; Pat el; Walsh; Feeney; Dellinger; McCain; Vargas; Gates; Rogers; Mikkilineni; Landry; Cabrio; Jones; Olson; OConnell; Sulliv an; Mourgos; Gee; Perkins; Grant; Geoni; Philtanker; Markle 60 Austin; Pataballa; Lorentz; Ernst; Hunold 70 Baer
with base_data as ( Ref ![]() |
Posted by
Ook
at
04:09
0
comments
Labels: Oracle
Subscribe to:
Posts (Atom)






