Solved

Tracing down all the service info on a LINUX system ???

Posted on 2011-02-22
8
596 Views
Last Modified: 2012-06-21
Hello Experts,

I got this production server to manage and I'm planing to deploy a new identical server and discontinue with the existing one.

But I'm confused to understand and trace current service versions and all inside this BOX. This is highly customized server. Can you help me with commands to identify below services versions and further more details ?

Apache
PHP
MySQL
Ruby on Rails (Rakefile.rb file are running)
etc..

Thanks a lot for time !
 
##############Login Banner#############################
ARNING! The remote SSH server rejected X11 forwarding request.
Last login: Thu Jan 27 10:07:58 2011 from 1xx.x.6.18
Linux 16438-39591 2.6.18-6-686 #1 SMP Sun Feb 10 22:11:31 UTC 2008 i686

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
#########################################################

Open in new window

0
Comment
Question by:Shakthi777
  • 3
  • 2
  • 2
  • +1
8 Comments
 

Expert Comment

by:tsteens
ID: 34949604
Apache: httpd -V
PHP: php --version
MySQL: mysql --version

I'm not sure about Ruby, but the man pages will probably help you. Usually there are either a -V or --version switch to tell you versions.

There might be a lot of dependencies as well. You could use ldd to somehow track those, but that is no guarantee that you will catch them all. Many of the popular Linux distros uses package managers to handle dependencies. What kind of system are you? What kind of information to you need, if any, apart from what you get from my suggestions above?
0
 
LVL 14

Assisted Solution

by:small_student
small_student earned 334 total points
ID: 34949615
Is this RHEL/CentOS/Fedora or Ubuntu/Debian or something else

From your post I  can see its debian

To find disk size and paritions

fdisk -l

and

df -h

To find Memory info

free

For Versions

php -v  (This  will give you php version)
mysql -V (This is an upper case V and will give you mysql version)
apache2 -v (This will give you apache version)

Dont forget to check kernel and architecture

uname -a

Record all this information. Good Luck
0
 

Author Comment

by:Shakthi777
ID: 34950006
thanks  alot !

user1@16438-39591:~$ apache2 -v
-sh: apache2: command not found

when we deploying a identical second server, what are the other information we need ? except application data and the DBs ?
0
 

Expert Comment

by:tsteens
ID: 34950054
If you do not have apache2 available. Use httpd -V as I said earlier. Be sure to use capital V. What kind of system are you on?
Deploying an identical server could be very hard because that would include making sure everything is in the exact same version. However from what you hav given so far this seems to be a web server. As long as you get the versions for php, mysql, apache and any other package you use (frameworks, ruby) right you shouldn't have any problems if you use a package manager such as yum or aptitude. Make sure to copy all configuration files though. They should be in your /etc directory.
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
LVL 14

Accepted Solution

by:
small_student earned 334 total points
ID: 34950083
For apache try

httpd -v

I would check for all system packages that are installed. Under debian you can check this info from dpkg command. Sorry but I am not very experienced with dpkg. But I know you can do something called dselect and you can get a full list of everytihng installed and export this list to the new server and have  them all installed from the debian repos by using apt-get.

I would check

1- Kernel and Arch
2- Disk size and partitioning
3- Memory and CPU info
4- Packages installed and their versions
5- User accounts
6- Data size
7- FIrewall rules if any apply
8- Ask the last system admin that was working on this server for any specific info or unusual things he had working that might not appear from simple tests on the server
9- Check what scripts are running if any (You have to check logs, search the system or ask as they dont have a specific place)
10- Check the cron system for any system crons.
0
 
LVL 12

Assisted Solution

by:mccracky
mccracky earned 166 total points
ID: 34953644
for debian, you can also get a listing of what all packages are installed on the system with

dpkg -l

you can pipe it into a file for reference for when you set up the new system.
0
 

Author Comment

by:Shakthi777
ID: 35127202
something happened when I'm trying to assign points and it's now in close mode. ???
0
 

Author Closing Comment

by:Shakthi777
ID: 35127209
tnx !
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now