Sponsored Content
Top Forums UNIX for Advanced & Expert Users how to know how many user's connected to ftp and http server Post 70338 by hariprasad on Wednesday 27th of April 2005 04:16:50 PM
Old 04-27-2005
Data how to know how many user's connected to ftp and http server

i need to write a program to know how many users are presently connected to my ftp server and http server .
i need to keep a count of this and this count should be available to other different software . how to make this GLOBAL so that other softwares can access this count value
 

10 More Discussions You Might Find Interesting

1. Cybersecurity

List of HTTP/FTP-clients on a server

The other day, a friend of mine had his Linux webserver compromised because he was running a vulnerable PHP-script. The "hacker" had used a malformed URL to include a wget-command to fetch some stuff off the net and install it in /dev/shm where it ran undetected. Fortunately, the webserver ran as a... (2 Replies)
Discussion started by: indo1144
2 Replies

2. Shell Programming and Scripting

Dowloading a File from FTP Server to a local Server where User Id's are different

Hi, The Setup is like this. I'm connecting to Unix machine from my local machine. After connecting to Unix M/c, i need to connect FTP server. Am successful in connecting to FTP server, but am not able to download the file from the ftp server to my local machine. I have different user id's and... (1 Reply)
Discussion started by: ranjith_taurean
1 Replies

3. HP-UX

FTP user information on destination server

Could any one please tell me how to check the ftp users information on the destination server ( Hp-UX ) ? Source server used to do FTP to my server ( that is destination server ) . Now , he is getting error that login is incorrect and unable to login into destination server . Please tell me how to... (3 Replies)
Discussion started by: randhir
3 Replies

4. Red Hat

SAN Connected RedHat Server

I received 4 pre-loaded ready-to-go intel servers running RedHat Enterprise Linux 3 kernel version 2.6.9-22.18 build date june 29, 2006. They are equiped with QLOGIC 2400 dual-port HBA cards. I need to know what utilities or command-sets are available to check these cards out? How do I get their... (4 Replies)
Discussion started by: sallender
4 Replies

5. Linux

How do I run HTTP server on port 80 using a non root user?

Hi experts, I want to run HTTP server on port 80, I learn from somewhere that it MUST not be run as root for security reason, how to do that? Thank you in advance! (14 Replies)
Discussion started by: kevintse
14 Replies

6. Solaris

Command see all devices connected to Sun server

Hi All, How to view all devices connected to Sun E2900. I wan to view all components attached to it. Please help Regards, NSkumar (3 Replies)
Discussion started by: nskumar
3 Replies

7. Solaris

How to execute a ".profile" depending on the server from where the user is connected.

Hello, I have two Solaris servers on a cluster. I have created the same user "X"on the two nodes (same UID and same GID). The file ".profile" of this user "X" is located in a filesystem that is seen by the two nodes. Each server should have a ".profile" of this user different of the other... (6 Replies)
Discussion started by: adilyos
6 Replies

8. Red Hat

Redhat server is not connected via putty

i have a redhat linux 5.3 machine. i can ping that machine remotely from my laptop. but when i connect that server via putty after providing username and password there is wait for some minutes and then i get error message "server unexpectedly closed network connection" Please guide... (2 Replies)
Discussion started by: rehantayyab82
2 Replies

9. UNIX for Dummies Questions & Answers

Ftp showing connected only

hi, good morning. Anyone can help me out. A trying to ftp from server A to server B. from server A to B its working fine but from server B to A, its only showing connected only: finap7 #ftp 10.10.10.210 Connected to 10.10.10.210. I refresh the inetd but nothing is happening. Please... (1 Reply)
Discussion started by: kamaldev
1 Replies

10. Shell Programming and Scripting

How to get user to choose files to be copied to FTP server?

Hey all. I'm writing a script to automatically login to a router, change directories to where crashfiles are located, then listing all files in that directory. This is where I'm at so far and wish to have some user interaction to choose the files. What I am trying to do is list the files and get... (1 Reply)
Discussion started by: Gouda
1 Replies
Thread::Semaphore(3pm)					 Perl Programmers Reference Guide				    Thread::Semaphore(3pm)

NAME
Thread::Semaphore - Thread-safe semaphores VERSION
This document describes Thread::Semaphore version 2.12 SYNOPSIS
use Thread::Semaphore; my $s = Thread::Semaphore->new(); $s->down(); # Also known as the semaphore P operation. # The guarded section is here $s->up(); # Also known as the semaphore V operation. # Decrement the semaphore only if it would immediately succeed. if ($s->down_nb()) { # The guarded section is here $s->up(); } # Forcefully decrement the semaphore even if its count goes below 0. $s->down_force(); # The default value for semaphore operations is 1 my $s = Thread::Semaphore->new($initial_value); $s->down($down_value); $s->up($up_value); if ($s->down_nb($down_value)) { ... $s->up($up_value); } $s->down_force($down_value); DESCRIPTION
Semaphores provide a mechanism to regulate access to resources. Unlike locks, semaphores aren't tied to particular scalars, and so may be used to control access to anything you care to use them for. Semaphores don't limit their values to zero and one, so they can be used to control access to some resource that there may be more than one of (e.g., filehandles). Increment and decrement amounts aren't fixed at one either, so threads can reserve or return multiple resources at once. METHODS
->new() ->new(NUMBER) "new" creates a new semaphore, and initializes its count to the specified number (which must be an integer). If no number is specified, the semaphore's count defaults to 1. ->down() ->down(NUMBER) The "down" method decreases the semaphore's count by the specified number (which must be an integer >= 1), or by one if no number is specified. If the semaphore's count would drop below zero, this method will block until such time as the semaphore's count is greater than or equal to the amount you're "down"ing the semaphore's count by. This is the semaphore "P operation" (the name derives from the Dutch word "pak", which means "capture" -- the semaphore operations were named by the late Dijkstra, who was Dutch). ->down_nb() ->down_nb(NUMBER) The "down_nb" method attempts to decrease the semaphore's count by the specified number (which must be an integer >= 1), or by one if no number is specified. If the semaphore's count would drop below zero, this method will return false, and the semaphore's count remains unchanged. Otherwise, the semaphore's count is decremented and this method returns true. ->down_force() ->down_force(NUMBER) The "down_force" method decreases the semaphore's count by the specified number (which must be an integer >= 1), or by one if no number is specified. This method does not block, and may cause the semaphore's count to drop below zero. ->up() ->up(NUMBER) The "up" method increases the semaphore's count by the number specified (which must be an integer >= 1), or by one if no number is specified. This will unblock any thread that is blocked trying to "down" the semaphore if the "up" raises the semaphore's count above the amount that the "down" is trying to decrement it by. For example, if three threads are blocked trying to "down" a semaphore by one, and another thread "up"s the semaphore by two, then two of the blocked threads (which two is indeterminate) will become unblocked. This is the semaphore "V operation" (the name derives from the Dutch word "vrij", which means "release"). NOTES
Semaphores created by Thread::Semaphore can be used in both threaded and non-threaded applications. This allows you to write modules and packages that potentially make use of semaphores, and that will function in either environment. SEE ALSO
Thread::Semaphore Discussion Forum on CPAN: <http://www.cpanforum.com/dist/Thread-Semaphore> threads, threads::shared MAINTAINER
Jerry D. Hedden, <jdhedden AT cpan DOT org> LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.18.2 2013-11-04 Thread::Semaphore(3pm)
All times are GMT -4. The time now is 09:17 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy