Elxis CMS Forum
Ελληνικό Forum => Δημόσιο Βήμα => Topic started by: ArXoS on March 05, 2009, 00:34:23
-
Βρε παιδιά, για ρίξτε μια ματιά εδώ ...
http://www.cpanelconfig.com/optimize-a-cpanel-server/install-mysql-performance-tuning-primer-script/ (http://www.cpanelconfig.com/optimize-a-cpanel-server/install-mysql-performance-tuning-primer-script/)
αξίζει ?
-
Γεια Αρχος,
Tuning MySql ειναι εμπεδομενο στην μηχανισμος του. Η εντολη που βρισκεται στην ελχις OPTIMIZE στην διαχειρηση τις βασης δεδομενων απλο καλει την εντολη. Η ουσια ειναι οτι εαν η βαση δεν ειναι ηδη optimized απο την δημιουργια "το σχεδιαζμο", τοτε δεν το βοηθαει τιποτα.
Δεν πιστευω οτι κανενα εξοτερικο προγραμμα θα προσφερει τιποτα. Δεν ειναι σαν εχει σχεση με το Norton utilities.
Η ταχυτητα εχει περισσοτερο σχεση με τα SQL.
http://dev.mysql.com/doc/refman/5.0/en/optimize-table.html (http://dev.mysql.com/doc/refman/5.0/en/optimize-table.html)
-
Η ουσια ειναι οτι εαν η βαση δεν ειναι ηδη optimized απο την δημιουργια "το σχεδιαζμο", τοτε δεν το βοηθαει τιποτα.
Why? Γιατί δεν το βοηθάει αυτό ή οποιοδήποτε άλλο εργαλείο;
-
Εγώ θα σου έλεγα Arxos να το δοκιμάσεις, δεν χάνεις τίποτα, ούτε (φαντάζομαι) υπάρχει κύνδινος κάποιας ζημιάς. Δεν θα σου κάνει τίποτα παραπάνω παρά έναν έλεγχο ρυθμίσεων και θα σου προτείνει να αλλάξεις κάποιες ρυθμίσεις για βελτίωση της ταχύτητας. Κάντο και πες μας αποτελέσματα.
-
Τώρα που το φερε η κουβέντα, υπάρχει δυνατότητα δημιουργίας ενός cron job μέσω cPanel, για να κάνει optimize & repair μια βάση δεδομένων;
-
Ναι αμέ, μπορείς να το κάνεις είτε φτιάχνοντας ένα shell script είτε ένα php script και μετά το βάζεις στο cron tab. Ότι θες μπορείς να τρέχεις με cron job. Το optimize χρειάζεται, καθαρίζει πολύ σαβούρα στη βάση. Ειδικά ότι αφορά πίνακες που γράφονται-σβήνονται συχνά όπως των sessions.
-
Οπως παντα, BACKUP πρωτο.
-
Εγώ θα σου έλεγα Arxos να το δοκιμάσεις, δεν χάνεις τίποτα, ούτε (φαντάζομαι) υπάρχει κύνδινος κάποιας ζημιάς. Δεν θα σου κάνει τίποτα παραπάνω παρά έναν έλεγχο ρυθμίσεων και θα σου προτείνει να αλλάξεις κάποιες ρυθμίσεις για βελτίωση της ταχύτητας. Κάντο και πες μας αποτελέσματα.
Όντως, έναν έλεγχο έκανε συγκρίνοντας history data για τα όρια της mysql, και έχει βγάλει 2-3 σελίδες με προτεινόμενες αλλαγές.
Να σας πω την αλήθεια, καμιά 10αρια τις ήξερα και το είχα κανα νου κάποτε να τις αλλάξω .. τις υπόλοιπες όμως παραμέτρους, ούτε που τις γνώριζα
Θα δοκιμάσω και θα σας πω συμπεριφορά στο Vps
-
OK. Αν θες κάνε copy-paste εδώ τα σημαντικότερα από όσα σου πρότεινε.
-
οκ .. βάζω όσα μου κοκκίνισε .. τα υπόλοιπα τα πέρασα με επιτυχία (values seems to be fine)
SLOW QUERIES
The slow query log is NOT enabled.
Current long_query_time = 10 sec.
You have 11 out of 5525229 that take longer than 10 sec. to complete
Your long_query_time may be too high, I typically set this under 5 sec.
BINARY UPDATE LOG
The binary update log is NOT enabled.
You will not be able to do point in time recovery
See http://dev.mysql.com/doc/refman/5.0/en/point-in-time-recovery.html
MAX CONNECTIONS
Current max_connections = 500
Current threads_connected = 3
Historic max_used_connections = 27
The number of used connections is 5% of the configured maximum.
You are using less than 10% of your configured max_connections.
Lowering max_connections could help to avoid an over-allocation of memory
See "MEMORY USAGE" section to make sure you are not over-allocating
QUERY CACHE
Query cache is supported but not enabled
Perhaps you should set the query_cache_size
JOINS
./tuning-primer.sh: line 332: bc: command not found
Current join_buffer_size = K
You have had 2815 queries where a join could not use an index properly
You should enable "log-queries-not-using-indexes"
Then look for non indexed joins in the slow query log.
If you are unable to optimize your queries you may want to increase your
join_buffer_size to accommodate larger joins in one pass.
Note! This script will still suggest raising the join_buffer_size when
ANY joins not using indexes are found.
TABLE CACHE
Current table_cache value = 4 tables
You have a total of 233 tables
You have 4 open tables.
Current table_cache hit rate is 0%, while 100% of your table cache is in use
You should probably increase your table_cache
TEMP TABLES
./tuning-primer.sh: line 332: bc: command not found
Current max_heap_table_size = M
./tuning-primer.sh: line 332: bc: command not found
Current tmp_table_size = M
Of 47286 temp tables, 30% were created on disk
Effective in-memory tmp_table_size is limited to max_heap_table_size.
Perhaps you should increase your tmp_table_size and/or max_heap_table_size
to reduce the number of disk-based temporary tables
Note! BLOB and TEXT columns are not allow in memory tables.
If you are using these columns raising these values might not impact your
ratio of on disk temp tables.
TABLE LOCKING
Current Lock Wait ratio = 1 : 1286
You may benefit from selective use of InnoDB.
If you have long running SELECT's against MyISAM tables and perform
frequent updates consider setting 'low_priority_updates=1'
If you have a high concurrency of inserts on Dynamic row-length tables
consider setting 'concurrent_insert=2'.