for install perl time hires you can use yum
open SSH and enter this command
yum install perl-Time-HiRes
have nice time
for install perl time hires you can use yum
open SSH and enter this command
yum install perl-Time-HiRes
have nice time
nmap must be run as root.
Run this command in SSH
nmap -sP 192.168.2.*
Starting Nmap 4.11 ( http://www.insecure.org/nmap/ ) at 2010-03-31 12:39 EDT
Host 192.168.2.1 appears to be up.
MAC Address: 00:01:B2:60:E0:AA (Intel)
Host 192.168.2.2 appears to be up.
MAC Address: 00:05:B6:40:E0:A3 (Intel)
Host 192.168.2.3 appears to be up.
MAC Address: 00:07B5:60:E0:A3 (Intel)
Host 192.168.2.11 appears to be up.
MAC Address: 00:13:2F:3B:B6:AC (Unknown)
Host 192.168.2.34 appears to be up.
MAC Address: 00:1F:C6:C9:A7:54 (Unknown)
Host 192.168.2.39 appears to be up.
MAC Address: 00:15:A4:35:55:EF (Global Data Services)
Host 192.168.2.50 appears to be up.
MAC Address: 00:1E:8C:04:A5:1F (Unknown)
Host 192.168.2.57 appears to be up.
MAC Address: 00:05:2D:E0:36:DF (D-Link Systems)
Host 192.168.2.71 appears to be up.
MAC Address: 00:03:47:A9:F3:D1 (Intel)
Host 192.168.2.79 appears to be up.
MAC Address: 00:1C:C0:9D:7F:9D (Unknown)
Host 192.168.2.80 appears to be up.
MAC Address: 00:1C:C0:9D:7D:51 (Unknown)
Host 192.168.2.82 appears to be up.
MAC Address: 00:16:53:23:1C:F4 (Foxconn)
its simple
At times, we need to install Perl modules that are not found in the official repository of a distribution. In that case, we have to revert to using cpan. CPAN stands for Comprehensive Perl Archive Network. It is an archive of over 16,000 modules of software written in Perl, as well as documentation for it. This tutorial will show you how to install a module using CPAN.
First we need to launch cpan. Type cpan in a terminal. If it is not already configured, then it will start to ask a series of questions. Just press Enter all the way until it asks for your location. Specify the location by entering the number for that location in the list shown. Then it will ask about your country, go ahead and type the number appropriate for your country. At the end you will see the cpan prompt like so
cpan>
To install a module, for example, Cache::Static, type the following at cpan prompt
cpan>install Cache::Static
It will ask you some questions, just press Enter to accept the defaults which almost always work. The module with all its dependencies will be downloaded, compiled and installed.
When you get back the cpan prompt, the module is installed.
Type quit to get out of cpan
cpan>quit
To confirm that the module is installed successfully, run this command
perl -e "use Cache::Static"
If you get no output, it means the module is installed successfully.
If you see the error “/bin/sh: cc: command not found”, then gcc is not installed. Install it like this on Debian, Ubuntu
aptitude install gcc
On Red Hat, Centos, Fedore, the following will work
yum install gcc
Apache is obviously complaining about suexec in the apache error logs. I finally found the solution.
apt-get install apache2-suexec
Here is usable to0ls for tuning mysql to make best performance for your server
Set your site number variable for later use:
export SITEID=`pwd | awk -F\/ ‘{ print $3 }’`
Download mysqltuner.pl to your (gs) Grid-Service with the
following command:
wget -O mysqltuner.pl mysqltuner.pl
Fill in the forcemem option with the size of your
GridContainer and run the script with the following command:
perl mysqltuner.pl –host internal-db.s$SITEID.gridserver.com
–forcemem 128
Enter your database username and password when you see the
following:
Please enter your MySQL administrative login:
Please enter your MySQL administrative password:
The script should run and then display statistics and
recommendations. Sample output:
>> MySQLTuner 1.0.1 – Major Hayden <major@mhtx.net>
>> Bug reports, feature requests, and downloads at
http://mysqltuner.com/
>> Run with ‘–help’ for additional options and output
filtering
——– General Statistics ——————————–
——————
[--] Skipped version check for MySQLTuner script
[OK] Currently running supported MySQL version 5.0.77
[OK] Operating on 32-bit architecture with less than 2GB RAM
——– Storage Engine Statistics ————————-
——————
[--] Status: -Archive -BDB -Federated +InnoDB -ISAM -
NDBCluster
[--] Data in MyISAM tables: 122K (Tables: 99)
[--] Data in InnoDB tables: 52M (Tables: 155)
[!!] Total fragmented tables: 5
——– Performance Metrics ——————————-
——————
[--] Up for: 262d 23h 58m 26s (2M q [0.121 qps], 328K conn,
TX: 572M, RX: 207M)
[--] Reads / Writes: 66% / 34%
[--] Total buffers: 35.0M global + 2.7M per thread (100 max
threads)
[OK] Maximum possible memory usage: 303.7M (45% of installed
RAM)
[OK] Slow queries: 0% (3/2M)
[OK] Highest usage of available connections: 5% (5/100)
[OK] Key buffer size / total MyISAM indexes: 8.0M/401.0K
[!!] Key buffer hit rate: 93.9% (110K cached / 6K reads)
[OK] Query cache efficiency: 82.8% (932K cached / 1M selects)
[OK] Query cache prunes per day: 11
[OK] Sorts requiring temporary tables: 0% (0 temp sorts / 29K
sorts)
[OK] Temporary tables created on disk: 25% (88K on disk /
348K total)
[!!] Thread cache is disabled
[!!] Table cache hit rate: 0% (64 open / 184K opened)
[OK] Open file limit used: 8% (86/1K)
[OK] Table locks acquired immediately: 100% (339K immediate /
339K locks)
[!!] InnoDB data size / buffer pool: 52.6M/2.0M
——– Recommendations ———————————–
——————
General recommendations:
Run OPTIMIZE TABLE to defragment tables for better
performance
Enable the slow query log to troubleshoot bad queries
Set thread_cache_size to 4 as a starting value
Increase table_cache gradually to avoid file descriptor
limits
Variables to adjust:
thread_cache_size (start at 4)
table_cache (> 64)
innodb_buffer_pool_size (>= 52M)
Feel free to implement these suggestions at your own
discretion.
BEST REGARD
Hello All my friend
sometime when you want import large DB in PHPmyAdmin you will see this error “Fatal error: Maximum execution time of 300 seconds exceeded”
for fix this you need Root access and SSH
open SSH and enter this command :
locate config.default.php
after this u shod open config.default.php with VI or nano editor like this :
nano /var/www/html/phpMyAdmin-3.5.0-all-languages/libraries/config.default.php
but you should know that this adress may change in other version but just look for this file config.default.php .
when you open it with nano editor search this line :
$cfg['ExecTimeLimit'] = 300;
and now change exec time from 300 to 3600 or anything you want .
Save and Exit nano editor
and restart mysql service
Service mysqld restart
Well Done
have fun
There shouldn’t be any question that IIS is significantly more secure than its predecessors. Several key enhancements such as a reduced attack surface, minimum install by default, and enhanced application isolation deliver a robust and secure web platform. IIS also is enabled by default to present only static information (that is, to use applications or other dynamic content, you must manually enable them).
However, Microsoft products are also the most popular products to try to hack. For this reason, it’s important to secure the web server as much as possible. The more barriers there are, the less inclined a hacker would be to try to gain unauthorized access. Each component on the web server must be secure; the server is only as secure as its weakest point.
Continue reading “HowTo-Securing Internet Information Services 7.5( Windows Server 2008 )” »
Yesterday, I had to do some work on our Forefront Threat Management Gateway machine. When I brought up the TMG console, it gave me a strange error: “Refresh failed” with an error code of 0×80004005. It was inexplicable. A few days earlier, we noticed that the “Network Connections” in control panel showed no connections at all, but ipconfig showed them as expected. I ended up placing a call to Microsoft support. They suspected that the TMG console issue was caused by the inability to enumerate the network connections, and I was inclined to agree. Their specialist for these things said that there’s a registry key which sometimes gets corrupted, and you can delete it and reboot the server to fix the issue. After carefully reviewing to ensure that nothing else was the issue, that’s just what we did. After the reboot, the network connections showed, and the TMG console issues were solved as well. To do this fix yourself (the usual disclaimer: back up your registry before editing!), look up the following key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Network and delete the “Config” value.
Back in March, I set up our ISA 2006 server and configured the VPN on it. Since I have a static IP address at my home office, I created an access rule in ISA server that denied all external IP addresses access to the VPN. Me being me, I didn’t test, I assumed (big mistake) that this would work. Today, I found out that this was not sufficient to restrict VPN access by IP addresses. Searching the Internet, I did not find anyone with a good tutorial on how to do this, so here is mine.
This tutorial explains a basic configuration using PostgreSQL and CentOS. For detailed information about configuration parameter please read the PostgreSQL documentation which is very good organized.
First thing you should do is updating your system to the last patch level. Be sure all the other installed software on this system works with the newest patches and then simply update your CentOS with:
yum update
Now reboot and install PostgreSQL. I prefer the 8.4 version on CentOS as long as there is no newer stable one which is delivered via the official repository.
yum install postgresql84-server
Before the first start the database needs to be initialized with the following command:
service postgresql initdb
The output looks like this:
Start the service:
service postgresql start
and add it to your runlevel:
chkconfig –level 35 postgresql on
Now PostgreSQL is installed and running. Per default PostgreSQL data directory is located in /var/lib/pgsql/data. With no changes PostgreSQL service is only listening to localhost and is bound to 127.0.0.1. This is not practical if you plan to run database and application on different hosts via network connection.
To allow for example connections from your private network 192.168.1.0/24 add the following line in pg_hba.conf
host all all 192.168.1.0/24 trust
and change or add the following line in /var/lib/pgsql/data/postgresql.conf
listen_addresses = ‘*’
The database needs to be restarted after changing this files.
service postgresql restart
Be sure you only allow access to your database for hosts which really need it.