52AV璈A|52AV.ONE

 曉撖蝣
 蝡唾酉
敹急瑕
  • av隢憯BBS
  • 璈A
  • 芣瑟憭瘚
  • 鞎澆
  • 52av鋆貉摰
  • 銝剜-銝剖銝餅
     
亦: 3218|敺: 0
銝銝銝駁 銝銝銝駁

[mysql] MySQL 臬箏臬交隞

[銴鋆賡包
頝唾唳摰璅撅
璅銝
潸” 2015-6-23 08:22:56 | 芰閰脖 撣 |摨閬 |梯璅∪
[臬榜
% I4 j3 n. _: Jmysqldump -u userid -e -p db_Name > xxxxx.sql
& o" b; ?5 D9 y( ^+ v臬箔table:mysqldump -p -u userid dbname tablename > 52avtv_dzx20.201506242307.sql& W. |' l2 c" l0 B8 z0 V" w
臬箸鞈摨: mysqldump -p -u userid --all-databases > all-database.sql            1 ]! O& E! k6 r) }8 g$ ]/ C
       雿,臬啁桃鞈摨怎雿輻刻撣唾撖蝣潭憿,隞仿舀鞈摨怠交,雿輻刻撣唾銋亙臬箸頛摰
$ E- d, j0 L" K9 F' i8 r1 S[芸臬箇瑽]  : https://iter01.com/206843.html
' F- M- H# q& A  fmysqldump--opt-d鞈摨怠-uroot-p>xxx.sql
) H1 Z( g1 H& U: A6 J; V+ T[芸臬箄]9 `! e9 x7 ^8 S& S0 D. C+ |
mysqldump-t鞈摨怠-uroot-p>xxx.sql
+ i. V1 ?% |- ]8 ]) C( V' ~) u- }* v) a3 {) F5 E0 T3 S
瘜冽:    嗡誑銝餈唳隞文隞賣蝬脩箇 "502 bad gateway",敶梢踹迸ginx,芾 --single-transaction --quick 撠勗末鈭,憒銝:. M5 G% T) C+ D5 z+ `" p
mysqldump -u userid -e -p --single-transaction --quick db_Name > xxxxx.sql, ~0 a0 d9 a! C: X
憿:mysqldump: Got error: 1017: Can't find file: 'pre_forum_rsscache' (errno: 2) when using LOCK TABLES  j' |# _% N3 H3 ~
Sol: 芾皂ysqldump銝--lock-tables=false撠勗臭誑閫瘙箏憿
- `: T9 e$ x2 v2 m亥箇: mysqldump: Couldn't execute 'show create table `pre_forum_rsscache`': Can't find file: 'pre_forum_rsscache' (errno: 2) (1017),隞叼hpmyadmin餃交亦餌pre_forum_rsscache  雿輻其葉ls /var/lib/mysql/52avtv_dz/pre_forum_rsscache*  潛曉芣  pre_forum_rsscache.frm 1瑼獢 ,甇撣豢閰脰3瑼:
) c& j+ N" i" @4 R1 V6 l# Y% J-rw-rw---- 1 mysql mysql 8852 Jun  3 16:05 pre_forum_rsscache.frm0 j9 G' y: C& @' n2 Z# H2 h) P
-rw-rw---- 1 mysql mysql    0 Jun  3 16:05 pre_forum_rsscache.MYD, @2 x, @1 @  m5 r1 X
-rw-rw---- 1 mysql mysql 1024 Jun  3 16:05 pre_forum_rsscache.MYI( \7 P$ o( w" `+ a, _3 u* o
Sol:
: A+ c  M3 t! _1 [  d
私hpmyadmin ==SQL 銝隞:; Z) y% w3 m& V9 E' g- ]
  1. DROP TABLE IF EXISTS pre_forum_rsscache;
  2. CREATE TABLE pre_forum_rsscache (
  3. lastupdate int(10) unsigned NOT NULL DEFAULT '0',
  4. fid mediumint(8) unsigned NOT NULL DEFAULT '0',
  5. tid mediumint(8) unsigned NOT NULL DEFAULT '0',
  6. dateline int(10) unsigned NOT NULL DEFAULT '0',
  7. forum char(50) NOT NULL DEFAULT '',
  8. author char(15) NOT NULL DEFAULT '',
  9. `subject` char(80) NOT NULL DEFAULT '',
  10. description char(255) NOT NULL DEFAULT '',
  11. guidetype char(10) NOT NULL DEFAULT '',
  12. UNIQUE KEY tid (tid),
  13. KEY fid (fid,dateline)
  14. ) ENGINE=MYISAM DEFAULT CHARSET=utf8
銴鋆賭誨蝣
# s! o8 @, k+ V, P* \: e. z
隞賢停甇撣訾7 X# y0 o4 F# m
憿:  嗡蝙皂ariadb 5.5.68  隞賣箇頡rror:mysqldump: Couldn't execute 'SHOW TRIGGERS LIKE 'pre\_portal\_topic\_pic'': Can't read dir of './db_name/' (errno: 24) (1018)
/ }8 t* V( u& s7 v9 [- aSol:  open_files_limit(default=962) 憭芸,寧4096,望澆撅祆廝ead-only,/etc/my.cnf # ~! M; z$ E$ T5 d7 Q
嗅 service mariadb restart, r9 G4 I: g7 C& ?9 w
9 B8 S/ u5 ~0 X6 s$ o8 Y. J' @
[璇隞嗅臬榜
& j) V+ ^0 G; i/ j1 y6 o- d) X/ Umysqldump -u撣唾 -p撖蝣 -h銝餅 鞈摨 鞈銵 -w "sql璇隞" > 箄撓頝臬瑼獢
0 M6 g7 I4 z. M0 @靘:
9 ~2 E6 [1 Y5 h9 O, [mysqldump -uroot -p123456 -hlocalhost -e AREA_UTF8 city -w "c_id<10 " > /home/web/a.txt
+ u. X% C1 A) O. i5 P $ v$ k9 U9 I9 D, e& o
--no-create-info嚗-t; f+ ~# }$ r' s
芸箄嚗銝瘛餃 CREATE TABLE 隤伐憒撠箸澆搴QL隤伐芣insert into典
+ F8 _1 v. J! @. V: b--no-data嚗-d4 o, z" A* [* G8 c) v
銝撠箔遙雿鞈嚗芸箄摨怎瑽2 x/ b, }7 R# x% I/ n& B- ^0 H4 K
--quick嚗-q 0 _/ I1 D8 S8 K7 v
典箏之鞈敺剁撘瑕嗅 MySQL Server 亥岷敺閮湔亥撓綽銝臬敺閮敺摮刻園銝准
$ f/ v6 O4 j  j: [
5 y- w; ?6 s: u( S4 X! H( X
$ K9 D5 J0 y( r9 Z% b+ L1 J5 z[臬包
1 ?3 @+ B% ~7 }! O7 P: s# Emysql -u userid -p [-h localhost] db_Name < xxxxx.sql, G- {/ z2 x' ^
臬交鞈摨:   mysql -u userid -p < all-database.sql
# k% T& B- g, [7 M; }  W臬乩table :
3 i3 y! F2 O: x# q$ omysql -u userid -p -D dbname < cc5278_dzx20.ip2c.201506242307.sql- ]0 V/ }8 d: l; _
P.S憒臬交憭芸之憒7GB,臬交獢銋瑁銝隞:3 _. c3 l( Q( o, Y
mysql -uroot -p -e "set global net_buffer_length=1000000; set global max_allowed_packet=1000000000;"9 D: ]: ^& n0 T7 r# |) r
0 a7 ]3 ?& \( X0 v+ F3 o3 J
[臬箏蝡喳臬亙啣虫唬蜓璈]
9 D( {0 Y0 s" Y3 @; v! n7 Smysqldump -u [SOURCE_userid] -h [SOURCE_IP] -e -q --password=[SOURCE_PASSWORD] SOURCE_db_Name | mysql -u [DISTANCE_userid] --password=[DISTANCE_PASSWORD] -h [DISTANCE_IP] DISTANCE_db_Name
% T" u, @0 F( m[閮剖臬乩(批2Mb) by phpmyadmin]2 Q/ H1 h# }- \3 G6 q
http://www.av4u.info/forum.php?m ... e=1&extra=#pid20348
3 W. l" B( }, Z; ~) C, k9 T* d: }" a& l" |) x- @
4 Y6 i" P* C" {5 x

8 ~  Y5 E; i- s9 p+ B. g/ i# r, O* z9 N) H) E6 q

- T4 P4 ^' f: e# Z1 h% F. O
7 U0 B5 {2 R! [) X: p; ^% z' o$ ~2 N# o$ K& T5 b8 u
$ V. i: l- t1 _; s, t, C
( Q" h# b3 A1 ?  C/ }6 e$ ^  U5 U& u

: `- o* D3 d4 o3 E6 @0 d
" l7 W8 t/ x3 B/ e' {; N$ G3 m
$ R/ ^2 P7 l( Y- i3 A9 n7 Z6 c( X6 A/ ^9 t

2 I0 f' ~9 l1 Q9 h+ T4 [  Q9 G  m- X

雿輻券

祉蝛閬

BT蝳

砍憛批捆靘餉衣雯頝臬批捆蝝颲行粹嗥蝬脩嚗摰撟湔遛嚗嚗甇脖誑銝嗅啣摰嗆摰撟湧翩鈭箏ㄚ孵舫脣伐銝憿亙祉璇甈橘芣遛18甇 雓蝯脣亦閬賬粹脩芣遛18甇脖芣撟渡雯閬賜雯頝臭嗥批捆鞈閮嚗撱箄降典舫脰蝬脰楝批捆蝝蝯蝜ICRA蝝摰鋆閮剖 (粹蝯行霅 祉蝬脣銝蝝瘛函隢憯啣嚗祉閮剜蝞∠)

QQ|撠暺撅||52AV璈A

GMT+8, 2024-12-26 15:20 , Processed in 0.070850 second(s), 16 queries .

蝯∠.撱

[email protected] | QQ:2405733034     since 2015-01

鋆貉憒 敹恍敺 餈銵