ورود

توجه ! این یک نسخه آرشیو شده میباشد و در این حالت شما عکسی را مشاهده نمیکنید برای مشاهده کامل متن و عکسها بر روی لینک مقابل کلیک کنید : آموزش نصب ابزار مفید mytop



eh3@n
June 2nd, 2013, 00:24
سلام به دوستان !

آموزش نصب ابزار مفید mytop رو میزارم

این ابزار برای مانیتورینگ و مشاهده مصرف منابع یوزر از سرور مورد استفاده قرار میگیرد

وارد ssh شوید

در ریشه اصلی تایپ کنید


wget http://www.mysqlfanboy.com/mytop/mytop-1.9.tar.gz

سپس


tar zxpfv mytop-1.9.tar.gz

بعد از آن


cd mytop-1.9

در نهایت !


perl Makefile.PL && make && make install


تایپ کنید mytop اگر اجرا شد که هیچ اگر نشد ..


فایل زیر رو باز کنید


nano /usr/local/bin/mytop
این کد رو پیدا کنید


db => 'test',

با کد زیر جایگزین کنید


db => '',


مجدد تست کنید

ممکنه بازم ارور بده

من لیست ارور ها + راه حل مشکل رو در پایین مینویسم

ارور


# Error -bash: perl: command not found

راه حل


yum install perl

ارور


# Error Can't locate ExtUtils/MakeMaker.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at Makefile.PL line 1. BEGIN failed--compilation aborted at Makefile.PL line 1.

راه حل


yum install cpan

ارور



# Error Warning: prerequisite DBD::mysql 1 not found. Warning: prerequisite DBI 1.13 not found. Warning: prerequisite Term::ReadKey 2.1 not found.


راه حل


yum install perl-DBI perl-DBD-MySQL perl-TermReadKey

ارور


# Error -bash: make: command not found

راه حل


yum install make

ارور


# Error (during $ make test) PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/InnoDBParser.t .. Can't locate Test/More.pm in @INC (@INC contains: /root/innotop-1.8.1/blib/lib /root/innotop-1.8.1/blib/arch /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at t/InnoDBParser.t line 5. BEGIN failed--compilation aborted at t/InnoDBParser.t line 5. t/InnoDBParser.t .. Dubious, test returned 2 (wstat 512, 0x200) No subtests run Test Summary Report ------------------- t/InnoDBParser.t (Wstat: 512 Tests: 0 Failed: 0) Non-zero exit status: 2 Parse errors: No plan found in TAP output Files=1, Tests=0, 0 wallclock secs ( 0.02 usr 0.02 sys + 0.00 cusr 0.01 csys = 0.05 CPU) Result: FAIL Failed 1/1 test programs. 0/0 subt


راه حل


yum install yum install perl-Test*


ارور



# Error (during $ make test) PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/InnoDBParser.t .. Can't locate Time/HiRes.pm in @INC (@INC contains: /root/innotop-1.8.1/ /root/innotop-1.8.1/blib/lib /root/innotop-1.8.1/blib/arch /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at /root/innotop-1.8.1//innotop line 1372. BEGIN failed--compilation aborted at /root/innotop-1.8.1//innotop line 1372. Compilation failed in require at t/InnoDBParser.t line 18. # Looks like your test exited with 2 before it could output anything. t/InnoDBParser.t .. Dubious, test returned 2 (wstat 512, 0x200) Failed 3/3 subtests Test Summary Report ------------------- t/InnoDBParser.t (Wstat: 512 Tests: 0 Failed: 0) Non-zero exit status: 2 Parse errors: Bad plan. You planned 3 tests but ran 0. Files=1, Tests=0, 0 wallclock secs ( 0.01 usr 0.02 sys + 0.08 cusr 0.02 csys = 0.13 CPU) Result: FAIL Failed 1/1 test programs. 0/0 subtests failed. make: *** [test_dynamic] Error 2 # Fix $


راه حل


yum install perl-Time-HiRes

سایت سازنده : http://jeremy.zawodny.com/mysql/mytop/

13603