[CentOS] attack

2009-12-24 Thread Manu Verhaegen
Hi,

My server is under attack allows the attacker to abuse of a php script of a 
vhost. How can I find what is the script.

Regards,
  maverh






___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread John Doe
From: Manu Verhaegen 
> My server is under attack allows the attacker to abuse of a php script of a 
> vhost. How can I find what is the script.

Could you be more specific...?
Anything in the log files?

JD


  
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Tim Ke
Anything from the accesslogs?

2009/12/24 Manu Verhaegen 

> Hi,
>
> My server is under attack allows the attacker to abuse of a php script of a
> vhost. How can I find what is the script.
>
> Regards,
>  maverh
>
>
>
>
>
>
> ___
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos
>
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Pete
On Thu, 2009-12-24 at 11:31 +, Manu Verhaegen wrote:
> Hi,
> 
> My server is under attack allows the attacker to abuse of a php script of a 
> vhost. How can I find what is the script.
> 
> Regards,
>   maverh

Hi Maverh,

I know this may sound like a silly question but how do you know your
server is under attack ? As others have advised, have you checked your
logs on the server ? What are you running that's being attacked ?

/var/log/httpd

/var/log/messages


Regards,

Pete.

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread david
Triying find to what are users running on spacific command, you should using 
top or ps or netstat please read the manual how to use it. After all and you 
get some info unpluge your server from internet, see what log says.

--Original Message--
From: Manu Verhaegen
Sender: centos-boun...@centos.org
To: centos@centos.org
ReplyTo: CentOS mailing list
Subject: [CentOS] attack
Sent: Dec 24, 2009 6:31 PM

Hi,

My server is under attack allows the attacker to abuse of a php script of a 
vhost. How can I find what is the script.

Regards,
  maverh






___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Warm regards,
David
-
./nobody
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Manu Verhaegen
Hi,

We have plesk running, i have running logwatch and i have found a IP adress.
I have add it in the IP table to block it then the attack is solved.
We see a lot of outgouing emails a php script is used for sending many emails 
possible stored in the database.

I have use  the following command
grep 'ipadres' /var/www/vhosts/*/statistics/logs/access_log
grep 'ipadres' /var/log/httpd/access.log

it do not find any record.

Regards,
  Manu Verhaegen



-Oorspronkelijk bericht-
Van: centos-boun...@centos.org [mailto:centos-boun...@centos.org] Namens Pete
Verzonden: donderdag 24 december 2009 12:45
Aan: CentOS mailing list
Onderwerp: Re: [CentOS] attack

On Thu, 2009-12-24 at 11:31 +, Manu Verhaegen wrote:
> Hi,
> 
> My server is under attack allows the attacker to abuse of a php script of a 
> vhost. How can I find what is the script.
> 
> Regards,
>   maverh

Hi Maverh,

I know this may sound like a silly question but how do you know your
server is under attack ? As others have advised, have you checked your
logs on the server ? What are you running that's being attacked ?

/var/log/httpd

/var/log/messages


Regards,

Pete.

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos



___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Manu Verhaegen
at the moment everiting is solved i have block the IP adress but i d'ont have 
found the script


>- Oorspronkelijk bericht -
>Van
: da...@pnyet.web.id [mailto:da...@pnyet.web.id]
>Verzonden
: donderdag
, december
 24, 2009 01:07 PM
>Aan
: 'CentOS mailing list'
>Onderwerp
: Re: [CentOS] attack
>
>Triying find to what are users running on spacific command, you should using 
>top or ps or netstat please read the manual how to use it. After all and you 
>get some info unpluge your server from internet, see what log says.
>
>--Original Message--
>From: Manu Verhaegen
>Sender: centos-boun...@centos.org
>To: centos@centos.org
>ReplyTo: CentOS mailing list
>Subject: [CentOS] attack
>Sent: Dec 24, 2009 6:31 PM
>
>Hi,
>
>My server is under attack allows the attacker to abuse of a php script of a 
>vhost. How can I find what is the script.
>
>Regards,
>  maverh
>
>
>
>
>
>
>___
>CentOS mailing list
>CentOS@centos.org
>http://lists.centos.org/mailman/listinfo/centos
>
>
>Warm regards,
>David
>-
>./nobody
>___
>CentOS mailing list
>CentOS@centos.org
>http://lists.centos.org/mailman/listinfo/centos
>
>


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Thomas Dukes
 

> -Original Message-
> From: centos-boun...@centos.org 
> [mailto:centos-boun...@centos.org] On Behalf Of Manu Verhaegen
> Sent: Thursday, December 24, 2009 7:04 AM
> To: CentOS mailing list
> Subject: Re: [CentOS] attack
> 
> at the moment everiting is solved i have block the IP adress 
> but i d'ont have found the script
> 

So you are the attacker.  Happened to me a couple weeks ago.

Check your tmp directory and subdirectory for std, udp.pl.  Also check
/etc/passwd and /etc/shadow for unusual users.  Should be at the very bottom
of those files.

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Inquiry:yum?

2009-12-24 Thread Jim Perrin
On Thu, Dec 24, 2009 at 1:58 AM, hadi motamedi  wrote:

> Thank you very much for your kind contineous support . At last , I have yum
> on my client .


Now please run a 'yum update' as you have several packages with known,
published security vulnerabilities including your kernel, and udev.
Doing this will take you to 5.4 and will require a reboot to load the
new kernel.


-- 
During times of universal deceit, telling the truth becomes a revolutionary act.
George Orwell
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Karanbir Singh
Hello

On 12/24/2009 12:01 PM, Manu Verhaegen wrote:
> We have plesk running, i have running logwatch and i have found a IP adress.
> I have add it in the IP table to block it then the attack is solved.
> We see a lot of outgouing emails a php script is used for sending many emails 
> possible stored in the database.


you also have a broken email client, what are the chances that you could:

a) find an email client that preserves thread sanity
b) refrain from topposting unless absolutely necessary

-- 
Karanbir Singh
London, UK| http://www.karan.org/ | twitter.com/kbsingh
ICQ: 2522219  | Yahoo IM: z00dax  | Gtalk: z00dax
GnuPG Key : http://www.karan.org/publickey.asc
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Manu Verhaegen
Hi,

i have Check my tmp directory and subdirectorys for std, udp.pl no file exist.  
Also i have check /etc/passwd and /etc/shadow for unusual users.  

regards

-Oorspronkelijk bericht-
Van: centos-boun...@centos.org [mailto:centos-boun...@centos.org] Namens Thomas 
Dukes
Verzonden: donderdag 24 december 2009 13:08
Aan: 'CentOS mailing list'
Onderwerp: Re: [CentOS] attack

 

> -Original Message-
> From: centos-boun...@centos.org 
> [mailto:centos-boun...@centos.org] On Behalf Of Manu Verhaegen
> Sent: Thursday, December 24, 2009 7:04 AM
> To: CentOS mailing list
> Subject: Re: [CentOS] attack
> 
> at the moment everiting is solved i have block the IP adress 
> but i d'ont have found the script
> 

So you are the attacker.  Happened to me a couple weeks ago.

Check your tmp directory and subdirectory for std, udp.pl.  Also check
/etc/passwd and /etc/shadow for unusual users.  Should be at the very bottom
of those files.

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos



___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Inquiry:yum? - hijack

2009-12-24 Thread Rob Kampen

Barry Brimer wrote:

I tried for the other engaged rpm packages one-by-one . But at last , only
the following one remained as unresolved :
[r...@mss-1 tmp]# rpm -Uvh yum-fastestmirror-1.1.16-13.el5.centos.noarch.rpm
warning: yum-fastestmirror-1.1.16-13.el5.centos.noarch.rpm: Header V3 DSA
signature: NOKEY, key ID e8562897
error: Failed dependencies:
   yum >= 3.0 is needed by
yum-fastestmirror-1.1.16-13.el5.centos.noarch
Can you please let me know why it does not come to an end ?



What is the output of "lsb_release -a"
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
  
Forgive me for thread stealing - lsb  3.1 is the current CentOS 
supported version.
I have some postscript / cups / printer drivers that insist on lsb 3.2 - 
anyone know if this is possible?

TIA Rob
<>___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread R-Elists

> Hi,
> 
> i have Check my tmp directory and subdirectorys for std, 
> udp.pl no file exist.  Also i have check /etc/passwd and 
> /etc/shadow for unusual users.  
> 
> regards

Manu,

forgive me if i missed it when i deleted several of the posts in the thread
yet how hard is it to check all the pertinent logfiles?

unless this is a very sophisticated compromise that hides, moves, or deletes
things, or the management system is trash, the info you need is "typically"
in one or more of the various logfiles on the system

something as simple 

man less

less /var/log/httpd/access_log

less /var/log/httpd/error_log

replace appropriate logfile names as necessary...

in general, there are many you can look at to gain some wisdom...

 - rh

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Kai Schaetzl
Obviously, if you are running several vhosts and plesk you likely have 
other logs to check. Also, one can usually see the origin of the mail 
injection in the maillog (e.g. complaints about setting to an unsafe 
sender) or in the outgoing messages. At runtime you can see the connects 
with full URLs on the apache status page.

Kai

-- 
Kai Schätzl, Berlin, Germany
Get your web at Conactive Internet Services: http://www.conactive.com



___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


[CentOS] cups and LSB 3.2; was: Inquiry:yum? - hijack

2009-12-24 Thread R P Herrold
On Thu, 24 Dec 2009, Rob Kampen wrote:

> Forgive me for thread stealing - lsb  3.1 is the current CentOS supported 
> version.
> I have some postscript / cups / printer drivers that insist on lsb 3.2 - 
> anyone know if this is possible?

> TIA Rob

This (LSB 3.2 -- last in the 3 series) is not really bleeding 
edge [LSB 4 just got its first refresh in the 4 series, 4 
having been out about a year], but the LSB intentionally lags 
to get a superset of distributions observed practice in Linux, 
rather than pushing development

The printer driver folks are pushing (Apple 'bought' cups a 
couple years back and are pushing) new versions -- consider 
this:

Date: Thu, 17 Dec 2009 15:10:42
From: Till Kamppeter 
To: lsb-disc...@lists.linux-foundation.org,
Subject: lsb-di]  Uplift to OPVP 1.0 in LSB 4.1?

Hi,

at OpenPrinting we are currently approving OpenPrinting Vector 
(OPVP) as official standard, and so the question came up on 
which version of OPVP are we in the printing requirements of 
the LSB and whether we can uplift to 1.0 if needed/possible.

In Ghostscript OPVP 1.0 was introduced with the 8.63 release 
in the beginning of August 2008. Do all the enterprise distros 
under consideration of the LSB already ship Ghostscript 8.63? 
If so, I suggest that we uplift to OPVP 1.0.



and frankly this will cause pain as ISV's and 
enterprise distributions are really not set up to 'chase' 
development [not economically justifiable, as it explodes the 
'support matrix'].   Both Linux Standards Base, and Open 
Printing are housed at the Linux Foundation presently, but it 
is not a good fit as they have conflicting mandates as to 
pushing

A grand total of ZERO applications have certified to 3.2
http://ldn.linuxfoundation.org/lsb/certified/applications?filter0=**ALL**&filter1=3721
and the same number to 4.0.  That said there is exactly ONE 
under 3.1

I count 17 distributions certified under LSB 3.1, one under 
3.2, and five to 4.0 ... NOT including RHEL for the last two items. 
While there has been much talk talk from the LF 
representatives about 'privately engaging' CentOS' upstream, 
and my sporadic efforts to drag the issues into the feeder 
Fedora space attention, frankly there is nothing much to show 
for it so far.

One has to ask if the LSB is even relevant.

I would note that with minimal changes, CentOS 5 can be made 
to pass (with minimal exemptions) the LSB 4 test suite in 
trials, and that CentOS 4.2 is used in day to day testing at 
the LSB's test boxes, the disinterest in certifying to the 
LSB at CentOS' upstream is similarly not publicly obvious.

Really and truly, until large entity, commercial purchasing 
agents of enterprise Linux distributions start to insert a 
clause like:

The provided software from the Provider shall at all
times during the life of this contract conform to the
then current Linux Standards Base then-current standard,
and be noted as so certified at the the Linux Standards
Base website.  There shall be a 'recertification window'
of six months following each LSB release and each
'point update' or 'refresh' of the same.  The failure to
maintain such certifications shall constitue a tender
of a 'non-confoming' performance and goods under this
contract, and if permitted to remain uncured for thirty
days after notice from Purchaser to Provider, shall
give rise to remedies to the Purchaser hereunder.

The LSB 'carrot' of interoperability is unappealing to a 
Distribution, as all it does is make an offering 'less 
sticky' and permit easier transitions away and substitutions. 
As the Enterprise Linux market share leader in many segments, 
CentOS' upstream has an incentive to ignore 'chasing' the LSB 
certifications.


The tried and true method to solve this is to back build from 
other's later released sources (hopefully already packaged -- 
I see Oracle's EL in there and those sources should build on 
CentOS); failing that, solving the Fedora/RawHide chain _may_ 
be possible, but as Fedora seeks to be very fast moving, they 
unavoidably avoid providing huge dependency chains.

Perhaps I should start a sub-project to try to carve away the 
GUI 'Fedora fluff' in packaging from the TUI server 'meat and 
potatos' with some sub-packaging breaks and alternatives.  ;)

-- Russ herrold
herrold at owlriver dot com
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Manu Verhaegen
Hi,

i ame checking this

thanks,
  Manu


-Oorspronkelijk bericht-
Van: centos-boun...@centos.org [mailto:centos-boun...@centos.org] Namens Kai 
Schaetzl
Verzonden: donderdag 24 december 2009 15:32
Aan: centos@centos.org
Onderwerp: Re: [CentOS] attack

Obviously, if you are running several vhosts and plesk you likely have 
other logs to check. Also, one can usually see the origin of the mail 
injection in the maillog (e.g. complaints about setting to an unsafe 
sender) or in the outgoing messages. At runtime you can see the connects 
with full URLs on the apache status page.

Kai

-- 
Kai Schätzl, Berlin, Germany
Get your web at Conactive Internet Services: http://www.conactive.com



___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos



___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] [OT] Urgent request

2009-12-24 Thread Mike A. Harris
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

tdu...@sc.rr.com wrote:
>> mark
> 
> We have been searching the internet since Tuesday.
> 
> We have already tried installing a video card, that didn't work.  The beeps 
> at start up indicate to check the video ram. It will boot and run if we put 
> it in another pc. 
> 
> The server is running c-sytems software on a sco operating system.  They tell 
> us we can't pull the hard drive and move it to another pc - something about a 
> bug causing it to lose data.
> 
> I've been running linux systems since the late 80's.  I have never heard of 
> this but then, I have never run a sco system either.
^^^

I can't believe nobody commented about this yet...  ;o)

Linux didn't exist until 1991, so it would have been quite the feat to
be running it in the 1980's indeed.  ;o)

I can't believe everyone let that slip by...  ;o)

Merry Christmas!



- --
Mike A. Harris   Website: http://mharris.ca
Google Wave: mike.andrew.harris - at - googlewave.com
https://identi.ca/mharris | https://twitter.com/mikeaharris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.5 (GNU/Linux)

iD8DBQFLM4Id4RNf2rTIeUARAjGwAJ9DwO7c2USU3Xan2y3vy9iViNfoTQCgl7PD
+uyJGTHnAFhSi/FOa5xw4Z8=
=Xuql
-END PGP SIGNATURE-
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


[CentOS] environment-modules

2009-12-24 Thread m . roth
We've got a developer here who needs to use both java and openjdk. I was
giving her sudo for alternatives, but my manager would prefer that I look
into environment-modules. I've installed it, and I see it comes with
configurations for cvs and info... but nothing for java, and the man pages
doesn't seem to offer info on creating one.

Does anyone have a pointer to a howto, or maybe even a sample one?

Thanks in advance.

   mark

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Andy Sutton
http://www.atomicorp.com/wiki/index.php/Atomic_Secured_Linux

Wraps a lot of "good stuff" together for a plesk web server on CentOS.
Won't help much if you are already compromised, but it would be a good
addition.

 -Andy


On Thu, 2009-12-24 at 12:01 +, Manu Verhaegen wrote:
> Hi,
> 
> We have plesk running, i have running logwatch and i have found a IP adress.
> I have add it in the IP table to block it then the attack is solved.
> We see a lot of outgouing emails a php script is used for sending many emails 
> possible stored in the database.
> 
> I have use  the following command
> grep 'ipadres' /var/www/vhosts/*/statistics/logs/access_log
> grep 'ipadres' /var/log/httpd/access.log
> 
> it do not find any record.
> 
> Regards,
>   Manu Verhaegen
> 
> 
> 
> -Oorspronkelijk bericht-
> Van: centos-boun...@centos.org [mailto:centos-boun...@centos.org] Namens Pete
> Verzonden: donderdag 24 december 2009 12:45
> Aan: CentOS mailing list
> Onderwerp: Re: [CentOS] attack
> 
> On Thu, 2009-12-24 at 11:31 +, Manu Verhaegen wrote:
> > Hi,
> > 
> > My server is under attack allows the attacker to abuse of a php script of a 
> > vhost. How can I find what is the script.
> > 
> > Regards,
> >   maverh
> 
> Hi Maverh,
> 
> I know this may sound like a silly question but how do you know your
> server is under attack ? As others have advised, have you checked your
> logs on the server ? What are you running that's being attacked ?
> 
> /var/log/httpd
> 
> /var/log/messages
> 
> 
> Regards,
> 
> Pete.
> 
> ___
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos
> 
> 
> 
> ___
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] [OT] Urgent request

2009-12-24 Thread tdukes

 "Mike A. Harris"  wrote: 
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> tdu...@sc.rr.com wrote:
> >> mark
> > 
> > We have been searching the internet since Tuesday.
> > 
> > We have already tried installing a video card, that didn't work.  The beeps 
> > at start up indicate to check the video ram. It will boot and run if we put 
> > it in another pc. 
> > 
> > The server is running c-sytems software on a sco operating system.  They 
> > tell us we can't pull the hard drive and move it to another pc - something 
> > about a bug causing it to lose data.
> > 
> > I've been running linux systems since the late 80's.  I have never heard of 
> > this but then, I have never run a sco system either.
> ^^^
> 
> I can't believe nobody commented about this yet...  ;o)
> 
> Linux didn't exist until 1991, so it would have been quite the feat to
> be running it in the 1980's indeed.  ;o)
> 
> I can't believe everyone let that slip by...  ;o)
> 
> Merry Christmas!

Someone did and I meant the 90's
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] attack

2009-12-24 Thread Fernando Hallberg
Hi,

I'm have a repo with many security tools.. if you can test... i'm upload a few 
packages from fedora, other sources, and created by me..

http://flexbox.sourceforge.net/centos/5/i386/flexbox-release-1-1.noarch.rpm

Try to install sectool, and verify your system..

You can try to use fail2ban for list maillog, and blacklists ips...

I'm using fail2ban+shorewall+ipset

Fernando.

On Thu, 24 Dec 2009 14:48:30 +
"Manu Verhaegen"  wrote:

> Hi,
> 
> i ame checking this
> 
> thanks,
>   Manu
> 
> 
> -Oorspronkelijk bericht-
> Van: centos-boun...@centos.org [mailto:centos-boun...@centos.org] Namens Kai 
> Schaetzl
> Verzonden: donderdag 24 december 2009 15:32
> Aan: centos@centos.org
> Onderwerp: Re: [CentOS] attack
> 
> Obviously, if you are running several vhosts and plesk you likely have 
> other logs to check. Also, one can usually see the origin of the mail 
> injection in the maillog (e.g. complaints about setting to an unsafe 
> sender) or in the outgoing messages. At runtime you can see the connects 
> with full URLs on the apache status page.
> 
> Kai
> 
> -- 
> Kai Schätzl, Berlin, Germany
> Get your web at Conactive Internet Services: http://www.conactive.com
> 
> 
> 
> ___
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos
> 
> 
> 
> ___
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos


-- 
Fernando Hallberg 
Flex Digital Soluções em Redes de Dados
http://www.flexdigital.com.br
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] [OT] Urgent request

2009-12-24 Thread Corey Chandler
Mike A. Harris wrote:
>
> Linux didn't exist until 1991, so it would have been quite the feat to
> be running it in the 1980's indeed.  ;o)
>   

Nonsense.  My time machine runs Linux.

-- Corey / KB1JWQ
Member, Bermuda Triangle Expeditionary Force, 2003-1944
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] environment-modules

2009-12-24 Thread John R Pierce
m.r...@5-cent.us wrote:
> We've got a developer here who needs to use both java and openjdk. I was
> giving her sudo for alternatives, but my manager would prefer that I look
> into environment-modules. I've installed it, and I see it comes with
> configurations for cvs and info... but nothing for java, and the man pages
> doesn't seem to offer info on creating one.
>
> Does anyone have a pointer to a howto, or maybe even a sample one?
>   

install openjdk uia standard centos 5.x rpms, install Sun Java to 
/usr/java/jdk-whatever via the Sun tarball.

if you put /usr/java/jdk-whatever/bin first in the path, you'll be using 
the Sun java.  if you take it out of the path, you will be using the 
default distribution openjdk.


On som eof our development systems we have 3-4 different versions of Sun 
java we manage this way.
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] environment-modules

2009-12-24 Thread m . roth
> m.r...@5-cent.us wrote:
>> We've got a developer here who needs to use both java and openjdk. I was
>> giving her sudo for alternatives, but my manager would prefer that I
>> look into environment-modules. I've installed it, and I see it comes with
>> configurations for cvs and info... but nothing for java, and the man
>> pages doesn't seem to offer info on creating one.
>>
>> Does anyone have a pointer to a howto, or maybe even a sample one?
>
> install openjdk uia standard centos 5.x rpms, install Sun Java to
> /usr/java/jdk-whatever via the Sun tarball.

Already did that (btw, Sun doesn't give you a tarball, they give you a
self-extracting .bin).
>
> if you put /usr/java/jdk-whatever/bin first in the path, you'll be using
> the Sun java.  if you take it out of the path, you will be using the
> default distribution openjdk.

I'm trying to provide a simple method for switching between the two, and I
don't have any guarantee that someone *other* than this developer, who
seems knowledgeable, will have to do the same thing.

I reiterate: does anyone have any examples for a modulefile for java?

 mark


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] environment-modules

2009-12-24 Thread John R Pierce
m.r...@5-cent.us wrote:
>> if you put /usr/java/jdk-whatever/bin first in the path, you'll be using
>> the Sun java.  if you take it out of the path, you will be using the
>> default distribution openjdk.
>> 
>
> I'm trying to provide a simple method for switching between the two, and I
> don't have any guarantee that someone *other* than this developer, who
> seems knowledgeable, will have to do the same thing.
>
> I reiterate: does anyone have any examples for a modulefile for java?
>   

lets assume that at profile time, the sun java is -not- in the path, and 
the usual /usr/bni stuff is.
in pseudocode as I'm a little too fried/tired to work out the real code 
and I haven't been coding sh/bash scripts in a few months so it all 
blurs together...
put this as /usr/local/bin/jset or something 

export PATH,BASEPATH
if not exists $BASEPATH then BASEPATH=$PATH
switch $1:
   case "openjdk":
 PATH=$BASEPATH
 break;
   case "sun":
PATH=/path/to/sun/jdk/bin:$BASEPATH
break;
   case "somethign else":
 PATH=/path/to/something/else:$BASEPATH
 break;
   default:
 echo "Usage:  $0 {sun|openjdk|somethingelse}"
 break
endswitch;


this is the old school brute force method, doesn't rely on any external 
magic other than a sane initial PATH

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


[CentOS] kvm-shell

2009-12-24 Thread Michael Kress
Hi, I don't know if that already exists somewhere ... I've written it
for me and wanted to share it with you.
It's minimal kvm shell for end users - it allows them to
start/stop/reboot their own kvm guests.
http://www.michael-kress.de/2009/12/kvm-shell/
kvm-shell should run on all platforms.
Have fun.
Regards
Michael

-- 
Michael Kress, kr...@hal.saar.de

___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos