780 likes | 996 Views
DB-3: Tips for Database Administrators. Ask questions as we go if I am not clear about something. Warning: there is a mistake in these slides.. DB-3: Tips for Database Administrators. . . Topics. Tip Nr. 0x00Tip Nr. 0x16. DB-3: Tips for Database Administrators. Tip Number 0x00. If it is n
E N D
1. DB-3: Tips for Database Administrators
2. DB-3: Tips for Database Administrators Ask questions as we goif I am not clear about something.Warning: there is a mistake in these slides.
3. DB-3: Tips for Database Administrators Topics Tip Nr. 0x00
…
Tip Nr. 0x16
4. DB-3: Tips for Database Administrators Tip Number 0x00
5. DB-3: Tips for Database Administrators Tip Number 0x01
6. DB-3: Tips for Database Administrators Tip Number 0x02
7. DB-3: Tips for Database Administrators Read the man pages man man
man [ -s section ] name
Read the man pages!
8. DB-3: Tips for Database Administrators Tip Number 0x03
9. DB-3: Tips for Database Administrators SSH SSH replaces telnet, rlogin, rcp, rsh, etc.
All connections are encrypted
Use for remote access over Internet
10. DB-3: Tips for Database Administrators SSH Don’t need username, password login
Can also use certificates for authentication
Can send output of
local commands to remote host
remote commands to local host
Can do secure file transfer
scp and sftp
Can tunnel other protocols (e.g. X windows)
11. DB-3: Tips for Database Administrators Simple remote command execution
12. DB-3: Tips for Database Administrators Remote command output to local host
13. DB-3: Tips for Database Administrators Local output piped to remote host
14. DB-3: Tips for Database Administrators Remote backup piped to local file
15. DB-3: Tips for Database Administrators Turning off sshd password authentication
16. DB-3: Tips for Database Administrators Enabling SSH certificate authentication
17. DB-3: Tips for Database Administrators Enabling SSH certificate authentication 2
18. DB-3: Tips for Database Administrators More about SSH
19. DB-3: Tips for Database Administrators Tip Number 0x04
20. DB-3: Tips for Database Administrators SSH for Windows
21. DB-3: Tips for Database Administrators Tip Number 0x05
22. DB-3: Tips for Database Administrators After Imaging Do you use after-image journalling?
YOU SHOULD
AI records all database changes
Intended for
disaster recovery
hot standby on another machine
23. DB-3: Tips for Database Administrators AI Basics Add AI extents to database
Back up the database
Enable after-imaging
Archive ai extents as they become full
10.1 has an automatic archiver
OpenEdge DBA guide has details
24. DB-3: Tips for Database Administrators AI basics 2 A failure occurs and you lose your database …..
Fix the failure
replace disk, memory, machine, etc.
Restore the backup copy of your database
Roll forward all ai extents you archived
You do know where you put them, don’t you?
I hope they weren’t on the failed disk
When roll forward done, start database
Now you are back to where you were
25. DB-3: Tips for Database Administrators Tip Number 0x06
26. DB-3: Tips for Database Administrators Index rebuild scratch space
27. DB-3: Tips for Database Administrators Tip Number 0x07
28. DB-3: Tips for Database Administrators Tools uptime
find
top
lsof
ifconfig
vmstat
iostat
netstat
bzip2
29. DB-3: Tips for Database Administrators Tools: uptime
30. DB-3: Tips for Database Administrators Tools: top
31. DB-3: Tips for Database Administrators Tools:find find files modified more than 30 days ago
find . -mtime +30 -print
delete files modified more than 30 days ago
find . -mtime +30 -exec rm {} \;
find files bigger than 16k
find . -size +16384c -print
find . -size +32 -print
delete files bigger than 16k
find . -size +16384c -print | xargs -i rm \;Read the man page!
32. DB-3: Tips for Database Administrators Tools:lsof
33. DB-3: Tips for Database Administrators Tools:ifconfig
34. DB-3: Tips for Database Administrators Tools:ifconfig
35. DB-3: Tips for Database Administrators Tools:netstat
36. DB-3: Tips for Database Administrators Tools: netstat -s
37. DB-3: Tips for Database Administrators vmstat
38. DB-3: Tips for Database Administrators iostat
39. DB-3: Tips for Database Administrators Tools:bzip2
40. DB-3: Tips for Database Administrators Tools: Windows tabbed console
41. DB-3: Tips for Database Administrators Tools: windows tabbed console
42. DB-3: Tips for Database Administrators Tools: More Windoze Stuff
43. DB-3: Tips for Database Administrators Tools: Still More Windoze Stuff
44. DB-3: Tips for Database Administrators Tools: Solaris
45. DB-3: Tips for Database Administrators Tools: AIX svmon
46. DB-3: Tips for Database Administrators Tools: AIX vmstat
47. DB-3: Tips for Database Administrators Tip Number 0x08
48. DB-3: Tips for Database Administrators Windows scripting Cygwin
provides lots of Unix tools and a shell for Windows. Also SSH server
Download from: www.cygwin.com
Windows Services for UNIX Version 3.5
From Micro$oft, but free
Lots of goodies: Korn, C, bash shells, 350 UNIX commands, NFS, NFS gateway, telent, telnetd
Download from http://technet.microsoft.com/en-us/interopmigration/bb380242.aspx
49. DB-3: Tips for Database Administrators Tip Number 0x09
50. DB-3: Tips for Database Administrators Stop Windows indexing service Go to the Start menu, pick run.
Type services.msc, click OK.
Services dialog will show.
Right-click on indexing service to show properties dialog,
if service running, click stop.
select disabled.
click apply
close.
51. DB-3: Tips for Database Administrators Tip Number 0x0a
52. DB-3: Tips for Database Administrators User SRVANY to run Windows Services Lets you create “user defined” Windows services
Instructions and download fromhttp://www.tacktech.com/display.cfm?ttid=197
Warning:
This is not for n00bs.
Study before using
Read http://support.microsoft.com/kb/137890
53. DB-3: Tips for Database Administrators Tip Number 0x0b
54. DB-3: Tips for Database Administrators Enable Windows telnet login by name/passwd NTLM authentication by default
To fix:
run TLNTADMN
take menu pick no 3 (display/change …)
pick 7 (NTLM)
set value to 1
take menu pick no 4 (restart service)
BUT: don’t use telnet
55. DB-3: Tips for Database Administrators Tip Number 0x0c
56. DB-3: Tips for Database Administrators Scripting backup
57. DB-3: Tips for Database Administrators Tip Number 0x0d
58. DB-3: Tips for Database Administrators Scripting promon
59. DB-3: Tips for Database Administrators Tip Number 0x0e
60. DB-3: Tips for Database Administrators Scripting ai archiving
61. DB-3: Tips for Database Administrators Tip Number 0x0f
62. DB-3: Tips for Database Administrators How much space is being used?
63. DB-3: Tips for Database Administrators Tip Number 0x10
64. DB-3: Tips for Database Administrators List tables by storage area
65. DB-3: Tips for Database Administrators Listing of tables by storage area
66. DB-3: Tips for Database Administrators List tables by storage area
67. DB-3: Tips for Database Administrators List tables by storage area 2
68. DB-3: Tips for Database Administrators Tip Number 0x11
69. DB-3: Tips for Database Administrators List indexes by storage area and table
70. DB-3: Tips for Database Administrators Tip Number 0x12
71. DB-3: Tips for Database Administrators vi cheat sheet
72. DB-3: Tips for Database Administrators Tip Number 0x13
73. DB-3: Tips for Database Administrators protop Tom Bascom’s Open Source Progress 4GL VST based performance monitoring program
Displays tons of useful information
Study source code to learn how it is done
Download from
http://www.greenfieldtech.com/articles/protop.shtml
74. DB-3: Tips for Database Administrators Tip Number 0x14
75. DB-3: Tips for Database Administrators Adam Backman’s dba scripts Available on PEG: http://www.peg.com/utilities.html
Been aroud awhile, but very good
Stuff they do:
backup
check ai status
check db status
look for blocked clients
more …
Study code to learn how it is done
76. DB-3: Tips for Database Administrators Tip Number 0x15
77. DB-3: Tips for Database Administrators Where to learn more OpenEdge Database Administration Guide
PSDN: www.psdn.progress.com
Classes (not the only ones)
Bravepoint: bravepoint.com
White Star Software: wss.com
Progress DBA classes
http://www.progress.com/openedge/services/education/index.ssp
PSC Tech Support Knowledge Center
78. DB-3: Tips for Database Administrators Tip Number 0x16
79. DB-3: Tips for Database Administrators Questions