You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Ken Treimann <kc...@ncsu.edu> on 2007/11/07 03:51:49 UTC
Trying to implement GShell ssh command (jira issue GSHELL-16)
Hello,
I am attempting to implement this functionality for contribution, but am
running into this issue:
ERROR ComponentLookupException: Unable to lookup component
'org.apache.geronimo.gshell.command.Command', it could not be created
Basically I copied RshCommand, and created a secure channel by adding a
port forwarder using the PortForwardingL example from JSch. In my
initial investigation, I copied RshCommand, made no changes other than
the class name and command ID, ran it, and it successfully opened an rsh
to a rsh-server. After adding the port forwarder, a UserInfo helper
class used by the JSch session, and command-line options for the ssh
user and password, I get the error. I tried to undo everything I did to
return to what previously worked, but I still get the error. There is
some fundamental GShell-ness that I'm missing here, so can anyone give
me a clue where I should start?
Thanks,
-Ken
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Dillon <ja...@planet57.com>.
So you all sorted now?
--jason
On Nov 7, 2007, at 3:53 AM, Ken Treimann wrote:
> I had to add it to <dependencySets> in gshell-assembly/src/main/
> assembly/bin.xml. Works like a champ now.
>
> Thanks!
> -Ken
>
>
> Jason Dillon wrote:
>> Looks like the jsch*.jar is not in the lib/ dir.
>>
>> --jason
>>
>>
>> On Nov 6, 2007, at 6:35 PM, Jason Warner wrote:
>>
>>> Ken,
>>>
>>> I'm not sure if this is a good way to do it or not, but try adding
>>> the
>>> dependency to gshell/trunk/gshell-assembly/pom.xml. I'm curious to
>>> see what happens.
>>>
>>> ~Jason Warner
>>>
>>> On Nov 6, 2007 11:03 PM, Ken Treimann <kctreima at sign ncsu
>>> period edu> wrote:
>>>> Jason,
>>>>
>>>> Looks like it's having trouble finding JSch. I added
>>>> jsch-0.1.36.jar to
>>>> the Maven repository using mvn install:install-file, and added a
>>>> dependency to pom.xml for each of gshell-remote-client and
>>>> gshell-remote-common where it's used (it wouldn't even build
>>>> until I had
>>>> done this). What did I miss?
>>>>
>>>> Here's the stack trace in case there's anything I didn't see:
>>>>
>>>> treimann@daffy.local:/> ssh tcp://192.168.1.13:3000
>>>> INFO DefaultCommandExecutor [main] Executing (String): ssh
>>>> tcp://192.168.1.13:3000
>>>> DEBUG DefaultCommandLineBuilder [main] CommandLine
>>>> (org.apache.geronimo.gshell.parser.ASTCommandLine)
>>>> DEBUG DefaultCommandLineBuilder [main] Expression
>>>> (org.apache.geronimo.gshell.parser.ASTExpression)
>>>> DEBUG DefaultCommandLineBuilder [main] PlainString( ssh )
>>>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>>>> DEBUG DefaultCommandLineBuilder [main] PlainString(
>>>> tcp://192.168.1.13:3000 )
>>>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>>>> INFO DefaultCommandExecutor [main] Executing (ssh):
>>>> [tcp://192.168.1.13:3000]
>>>> DEBUG DefaultLayoutManager [main] Searching for command for
>>>> path: ssh
>>>> DEBUG PlexusCommandWrapper [main] Child container realm:
>>>> gshell:fbf112fb-ba13-49ee-8221-17608088e507
>>>> ERROR ComponentLookupException: Unable to lookup component
>>>> 'org.apache.geronimo.gshell.command.Command', it could not be
>>>> created
>>>> DEBUG DefaultShell [main]
>>>> org
>>>> .codehaus
>>>> .plexus.component.repository.exception.ComponentLookupException:
>>>> Unable to lookup component
>>>> 'org.apache.geronimo.gshell.command.Command',
>>>> it could not be created
>>>> org
>>>> .codehaus
>>>> .plexus.component.repository.exception.ComponentLookupException:
>>>> Unable to lookup component
>>>> 'org.apache.geronimo.gshell.command.Command',
>>>> it could not be created
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .DefaultComponentLookupManager
>>>> .lookup(DefaultComponentLookupManager.java:151)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:
>>>> 500)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .DefaultComponentLookupManager
>>>> .lookup(DefaultComponentLookupManager.java:133)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .DefaultComponentLookupManager
>>>> .lookup(DefaultComponentLookupManager.java:91)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:
>>>> 549)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:
>>>> 543)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo
>>>> .gshell
>>>> .plugin.PlexusCommandWrapper.execute(PlexusCommandWrapper.java:66)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo
>>>> .gshell
>>>> .DefaultCommandExecutor.execute(DefaultCommandExecutor.java:128)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:96)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo
>>>> .gshell.parser.ASTExpression.jjtAccept(ASTExpression.java:17)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo.gshell.parser.SimpleNode.childrenAccept(SimpleNode.java:
>>>> 57)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:79)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo
>>>> .gshell.parser.ASTCommandLine.jjtAccept(ASTCommandLine.java:17)
>>>> at
>>>> org.apache.geronimo.gshell.DefaultCommandLineBuilder
>>>> $1.execute(DefaultCommandLineBuilder.java:95)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo
>>>> .gshell
>>>> .DefaultCommandExecutor.execute(DefaultCommandExecutor.java:72)
>>>> at
>>>> org.apache.geronimo.gshell.DefaultShell.execute(DefaultShell.java:
>>>> 120)
>>>> at
>>>> org.apache.geronimo.gshell.DefaultShell
>>>> $1.execute(DefaultShell.java:152)
>>>> at
>>>> org.apache.geronimo.gshell.console.Console.work(Console.java:187)
>>>> at
>>>> org.apache.geronimo.gshell.console.Console.run(Console.java:128)
>>>> at
>>>> org
>>>> .apache
>>>> .geronimo.gshell.console.JLineConsole.run(JLineConsole.java:68)
>>>> at
>>>> org.apache.geronimo.gshell.DefaultShell.run(DefaultShell.java:213)
>>>> at org.apache.geronimo.gshell.GShell.run(GShell.java:156)
>>>> at org.apache.geronimo.gshell.cli.Main.boot(Main.java:247)
>>>> at org.apache.geronimo.gshell.cli.Main.main(Main.java:264)
>>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>>>> Method)
>>>> at
>>>> sun
>>>> .reflect
>>>> .NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>> at
>>>> sun
>>>> .reflect
>>>> .DelegatingMethodAccessorImpl
>>>> .invoke(DelegatingMethodAccessorImpl.java:25)
>>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:408)
>>>> at
>>>> org
>>>> .codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:
>>>> 351)
>>>> at
>>>> org.apache.geronimo.gshell.bootstrap.Launcher.main(Launcher.java:
>>>> 59)
>>>> Caused by:
>>>> org
>>>> .codehaus.plexus.component.factory.ComponentInstantiationException:
>>>> Could not instantiate component: role:
>>>> 'org.apache.geronimo.gshell.command.Command', implementation:
>>>> 'org.apache.geronimo.gshell.remote.client.SshCommand', role hint:
>>>> 'ssh'
>>>> realm: gshell:fbf112fb-ba13-49ee-8221-17608088e507
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .factory
>>>> .java
>>>> .JavaComponentFactory.makeException(JavaComponentFactory.java:113)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .factory
>>>> .java.JavaComponentFactory.newInstance(JavaComponentFactory.java:
>>>> 87)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .manager
>>>> .AbstractComponentManager
>>>> .createComponentInstance(AbstractComponentManager.java:239)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .manager
>>>> .AbstractComponentManager
>>>> .createComponentInstance(AbstractComponentManager.java:128)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .manager
>>>> .PerLookupComponentManager
>>>> .getComponent(PerLookupComponentManager.java:40)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .DefaultComponentLookupManager
>>>> .lookup(DefaultComponentLookupManager.java:147)
>>>> ... 32 more
>>>> Caused by: java.lang.NoClassDefFoundError: com/jcraft/jsch/UserInfo
>>>> at java.lang.Class.getDeclaredConstructors0(Native Method)
>>>> at
>>>> java.lang.Class.privateGetDeclaredConstructors(Class.java:2328)
>>>> at java.lang.Class.getConstructor0(Class.java:2640)
>>>> at java.lang.Class.newInstance0(Class.java:321)
>>>> at java.lang.Class.newInstance(Class.java:303)
>>>> at
>>>> org
>>>> .codehaus
>>>> .plexus
>>>> .component
>>>> .factory
>>>> .java.JavaComponentFactory.newInstance(JavaComponentFactory.java:
>>>> 66)
>>>> ... 36 more
>>>> treimann@daffy.local:/>
>>>>
>>>>
>>>> Thanks,
>>>> -Ken
>>>>
>>>>
>>>>
>>>> Jason Warner wrote:
>>>>> Ken,
>>>>>
>>>>> I am such a dork. I've been sitting here putzing around wishing
>>>>> for
>>>>> more information. Can you run GShell using the debug command?
>>>>> "./gsh
>>>>> --debug" I think. This should give a full stack trace for that
>>>>> error.
>>>>> Can you please post that stack trace?
>>>>>
>>>>> Thanks!
>>>>>
>>>>> Jason Warner.
>>>>>
>>>>
>>>>> On Nov 6, 2007 10:20 PM, Ken Treimann <kctreima at sign ncsu
>>>>> period edu> wrote:
>>>>>
>>>>>> Yes, when I run the new ssh command. Sorry for the confusion!
>>>>>>
>>>>>> Thanks,
>>>>>> -Ken
>>>>>>
>>>>>>
>>>>>> Jason Warner wrote:
>>>>>>
>>>>>>> Hi Ken,
>>>>>>>
>>>>>>> I'm a little confused by the order of events that transpired
>>>>>>> here.
>>>>>>> When do you get this error? When you try to run the command?
>>>>>>>
>>>>>>>
>>>>>>> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu
>>>>>>> period edu> wrote:
>>>>>>>
>>>>>>>
>>>>>>>> Hello,
>>>>>>>>
>>>>>>>> I am attempting to implement this functionality for
>>>>>>>> contribution, but am
>>>>>>>> running into this issue:
>>>>>>>>
>>>>>>>> ERROR ComponentLookupException: Unable to lookup component
>>>>>>>> 'org.apache.geronimo.gshell.command.Command', it could not be
>>>>>>>> created
>>>>>>>>
>>>>>>>> Basically I copied RshCommand, and created a secure channel
>>>>>>>> by adding a
>>>>>>>> port forwarder using the PortForwardingL example from JSch.
>>>>>>>> In my
>>>>>>>> initial investigation, I copied RshCommand, made no changes
>>>>>>>> other than
>>>>>>>> the class name and command ID, ran it, and it successfully
>>>>>>>> opened an rsh
>>>>>>>> to a rsh-server. After adding the port forwarder, a UserInfo
>>>>>>>> helper
>>>>>>>> class used by the JSch session, and command-line options for
>>>>>>>> the ssh
>>>>>>>> user and password, I get the error. I tried to undo
>>>>>>>> everything I did to
>>>>>>>> return to what previously worked, but I still get the error.
>>>>>>>> There is
>>>>>>>> some fundamental GShell-ness that I'm missing here, so can
>>>>>>>> anyone give
>>>>>>>> me a clue where I should start?
>>>>>>>>
>>>>>>>>
>>>>>>>> Thanks,
>>>>>>>> -Ken
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Ken Treimann <kc...@ncsu.edu>.
I had to add it to <dependencySets> in
gshell-assembly/src/main/assembly/bin.xml. Works like a champ now.
Thanks!
-Ken
Jason Dillon wrote:
> Looks like the jsch*.jar is not in the lib/ dir.
>
> --jason
>
>
> On Nov 6, 2007, at 6:35 PM, Jason Warner wrote:
>
>> Ken,
>>
>> I'm not sure if this is a good way to do it or not, but try adding the
>> dependency to gshell/trunk/gshell-assembly/pom.xml. I'm curious to
>> see what happens.
>>
>> ~Jason Warner
>>
>> On Nov 6, 2007 11:03 PM, Ken Treimann <kctreima at sign ncsu period
>> edu> wrote:
>>> Jason,
>>>
>>> Looks like it's having trouble finding JSch. I added
>>> jsch-0.1.36.jar to
>>> the Maven repository using mvn install:install-file, and added a
>>> dependency to pom.xml for each of gshell-remote-client and
>>> gshell-remote-common where it's used (it wouldn't even build until I
>>> had
>>> done this). What did I miss?
>>>
>>> Here's the stack trace in case there's anything I didn't see:
>>>
>>> treimann@daffy.local:/> ssh tcp://192.168.1.13:3000
>>> INFO DefaultCommandExecutor [main] Executing (String): ssh
>>> tcp://192.168.1.13:3000
>>> DEBUG DefaultCommandLineBuilder [main] CommandLine
>>> (org.apache.geronimo.gshell.parser.ASTCommandLine)
>>> DEBUG DefaultCommandLineBuilder [main] Expression
>>> (org.apache.geronimo.gshell.parser.ASTExpression)
>>> DEBUG DefaultCommandLineBuilder [main] PlainString( ssh )
>>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>>> DEBUG DefaultCommandLineBuilder [main] PlainString(
>>> tcp://192.168.1.13:3000 )
>>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>>> INFO DefaultCommandExecutor [main] Executing (ssh):
>>> [tcp://192.168.1.13:3000]
>>> DEBUG DefaultLayoutManager [main] Searching for command for
>>> path: ssh
>>> DEBUG PlexusCommandWrapper [main] Child container realm:
>>> gshell:fbf112fb-ba13-49ee-8221-17608088e507
>>> ERROR ComponentLookupException: Unable to lookup component
>>> 'org.apache.geronimo.gshell.command.Command', it could not be created
>>> DEBUG DefaultShell [main]
>>> org.codehaus.plexus.component.repository.exception.ComponentLookupException:
>>>
>>> Unable to lookup component
>>> 'org.apache.geronimo.gshell.command.Command',
>>> it could not be created
>>> org.codehaus.plexus.component.repository.exception.ComponentLookupException:
>>>
>>> Unable to lookup component
>>> 'org.apache.geronimo.gshell.command.Command',
>>> it could not be created
>>> at
>>> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:151)
>>>
>>> at
>>> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:500)
>>>
>>> at
>>> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:133)
>>>
>>> at
>>> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:91)
>>>
>>> at
>>> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:549)
>>>
>>> at
>>> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:543)
>>>
>>> at
>>> org.apache.geronimo.gshell.plugin.PlexusCommandWrapper.execute(PlexusCommandWrapper.java:66)
>>>
>>> at
>>> org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:128)
>>>
>>> at
>>> org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:96)
>>>
>>> at
>>> org.apache.geronimo.gshell.parser.ASTExpression.jjtAccept(ASTExpression.java:17)
>>>
>>> at
>>> org.apache.geronimo.gshell.parser.SimpleNode.childrenAccept(SimpleNode.java:57)
>>>
>>> at
>>> org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:79)
>>>
>>> at
>>> org.apache.geronimo.gshell.parser.ASTCommandLine.jjtAccept(ASTCommandLine.java:17)
>>>
>>> at
>>> org.apache.geronimo.gshell.DefaultCommandLineBuilder$1.execute(DefaultCommandLineBuilder.java:95)
>>>
>>> at
>>> org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:72)
>>>
>>> at
>>> org.apache.geronimo.gshell.DefaultShell.execute(DefaultShell.java:120)
>>> at
>>> org.apache.geronimo.gshell.DefaultShell$1.execute(DefaultShell.java:152)
>>>
>>> at
>>> org.apache.geronimo.gshell.console.Console.work(Console.java:187)
>>> at
>>> org.apache.geronimo.gshell.console.Console.run(Console.java:128)
>>> at
>>> org.apache.geronimo.gshell.console.JLineConsole.run(JLineConsole.java:68)
>>>
>>> at
>>> org.apache.geronimo.gshell.DefaultShell.run(DefaultShell.java:213)
>>> at org.apache.geronimo.gshell.GShell.run(GShell.java:156)
>>> at org.apache.geronimo.gshell.cli.Main.boot(Main.java:247)
>>> at org.apache.geronimo.gshell.cli.Main.main(Main.java:264)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at
>>> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
>>>
>>> at
>>> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
>>>
>>> at
>>> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:408)
>>>
>>> at
>>> org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:351)
>>>
>>> at
>>> org.apache.geronimo.gshell.bootstrap.Launcher.main(Launcher.java:59)
>>> Caused by:
>>> org.codehaus.plexus.component.factory.ComponentInstantiationException:
>>> Could not instantiate component: role:
>>> 'org.apache.geronimo.gshell.command.Command', implementation:
>>> 'org.apache.geronimo.gshell.remote.client.SshCommand', role hint: 'ssh'
>>> realm: gshell:fbf112fb-ba13-49ee-8221-17608088e507
>>> at
>>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.makeException(JavaComponentFactory.java:113)
>>>
>>> at
>>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:87)
>>>
>>> at
>>> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:239)
>>>
>>> at
>>> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:128)
>>>
>>> at
>>> org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:40)
>>>
>>> at
>>> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
>>>
>>> ... 32 more
>>> Caused by: java.lang.NoClassDefFoundError: com/jcraft/jsch/UserInfo
>>> at java.lang.Class.getDeclaredConstructors0(Native Method)
>>> at
>>> java.lang.Class.privateGetDeclaredConstructors(Class.java:2328)
>>> at java.lang.Class.getConstructor0(Class.java:2640)
>>> at java.lang.Class.newInstance0(Class.java:321)
>>> at java.lang.Class.newInstance(Class.java:303)
>>> at
>>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:66)
>>>
>>> ... 36 more
>>> treimann@daffy.local:/>
>>>
>>>
>>> Thanks,
>>> -Ken
>>>
>>>
>>>
>>> Jason Warner wrote:
>>>> Ken,
>>>>
>>>> I am such a dork. I've been sitting here putzing around wishing for
>>>> more information. Can you run GShell using the debug command? "./gsh
>>>> --debug" I think. This should give a full stack trace for that error.
>>>> Can you please post that stack trace?
>>>>
>>>> Thanks!
>>>>
>>>> Jason Warner.
>>>>
>>>
>>>> On Nov 6, 2007 10:20 PM, Ken Treimann <kctreima at sign ncsu period
>>>> edu> wrote:
>>>>
>>>>> Yes, when I run the new ssh command. Sorry for the confusion!
>>>>>
>>>>> Thanks,
>>>>> -Ken
>>>>>
>>>>>
>>>>> Jason Warner wrote:
>>>>>
>>>>>> Hi Ken,
>>>>>>
>>>>>> I'm a little confused by the order of events that transpired here.
>>>>>> When do you get this error? When you try to run the command?
>>>>>>
>>>>>>
>>>>>> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu
>>>>>> period edu> wrote:
>>>>>>
>>>>>>
>>>>>>> Hello,
>>>>>>>
>>>>>>> I am attempting to implement this functionality for
>>>>>>> contribution, but am
>>>>>>> running into this issue:
>>>>>>>
>>>>>>> ERROR ComponentLookupException: Unable to lookup component
>>>>>>> 'org.apache.geronimo.gshell.command.Command', it could not be
>>>>>>> created
>>>>>>>
>>>>>>> Basically I copied RshCommand, and created a secure channel by
>>>>>>> adding a
>>>>>>> port forwarder using the PortForwardingL example from JSch. In my
>>>>>>> initial investigation, I copied RshCommand, made no changes
>>>>>>> other than
>>>>>>> the class name and command ID, ran it, and it successfully
>>>>>>> opened an rsh
>>>>>>> to a rsh-server. After adding the port forwarder, a UserInfo helper
>>>>>>> class used by the JSch session, and command-line options for the
>>>>>>> ssh
>>>>>>> user and password, I get the error. I tried to undo everything I
>>>>>>> did to
>>>>>>> return to what previously worked, but I still get the error.
>>>>>>> There is
>>>>>>> some fundamental GShell-ness that I'm missing here, so can
>>>>>>> anyone give
>>>>>>> me a clue where I should start?
>>>>>>>
>>>>>>>
>>>>>>> Thanks,
>>>>>>> -Ken
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Dillon <ja...@planet57.com>.
Looks like the jsch*.jar is not in the lib/ dir.
--jason
On Nov 6, 2007, at 6:35 PM, Jason Warner wrote:
> Ken,
>
> I'm not sure if this is a good way to do it or not, but try adding the
> dependency to gshell/trunk/gshell-assembly/pom.xml. I'm curious to
> see what happens.
>
> ~Jason Warner
>
> On Nov 6, 2007 11:03 PM, Ken Treimann <kc...@ncsu.edu> wrote:
>> Jason,
>>
>> Looks like it's having trouble finding JSch. I added
>> jsch-0.1.36.jar to
>> the Maven repository using mvn install:install-file, and added a
>> dependency to pom.xml for each of gshell-remote-client and
>> gshell-remote-common where it's used (it wouldn't even build until
>> I had
>> done this). What did I miss?
>>
>> Here's the stack trace in case there's anything I didn't see:
>>
>> treimann@daffy.local:/> ssh tcp://192.168.1.13:3000
>> INFO DefaultCommandExecutor [main] Executing (String): ssh
>> tcp://192.168.1.13:3000
>> DEBUG DefaultCommandLineBuilder [main] CommandLine
>> (org.apache.geronimo.gshell.parser.ASTCommandLine)
>> DEBUG DefaultCommandLineBuilder [main] Expression
>> (org.apache.geronimo.gshell.parser.ASTExpression)
>> DEBUG DefaultCommandLineBuilder [main] PlainString( ssh )
>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>> DEBUG DefaultCommandLineBuilder [main] PlainString(
>> tcp://192.168.1.13:3000 )
>> (org.apache.geronimo.gshell.parser.ASTPlainString)
>> INFO DefaultCommandExecutor [main] Executing (ssh):
>> [tcp://192.168.1.13:3000]
>> DEBUG DefaultLayoutManager [main] Searching for command for
>> path: ssh
>> DEBUG PlexusCommandWrapper [main] Child container realm:
>> gshell:fbf112fb-ba13-49ee-8221-17608088e507
>> ERROR ComponentLookupException: Unable to lookup component
>> 'org.apache.geronimo.gshell.command.Command', it could not be created
>> DEBUG DefaultShell [main]
>> org.codehaus.plexus.component.repository.exception.ComponentLookupExc
>> eption:
>> Unable to lookup component
>> 'org.apache.geronimo.gshell.command.Command',
>> it could not be created
>> org.codehaus.plexus.component.repository.exception.ComponentLookupExc
>> eption:
>> Unable to lookup component
>> 'org.apache.geronimo.gshell.command.Command',
>> it could not be created
>> at
>> org.codehaus.plexus.DefaultComponentLookupManager.lookup
>> (DefaultComponentLookupManager.java:151)
>> at
>> org.codehaus.plexus.DefaultPlexusContainer.lookup
>> (DefaultPlexusContainer.java:500)
>> at
>> org.codehaus.plexus.DefaultComponentLookupManager.lookup
>> (DefaultComponentLookupManager.java:133)
>> at
>> org.codehaus.plexus.DefaultComponentLookupManager.lookup
>> (DefaultComponentLookupManager.java:91)
>> at
>> org.codehaus.plexus.DefaultPlexusContainer.lookup
>> (DefaultPlexusContainer.java:549)
>> at
>> org.codehaus.plexus.DefaultPlexusContainer.lookup
>> (DefaultPlexusContainer.java:543)
>> at
>> org.apache.geronimo.gshell.plugin.PlexusCommandWrapper.execute
>> (PlexusCommandWrapper.java:66)
>> at
>> org.apache.geronimo.gshell.DefaultCommandExecutor.execute
>> (DefaultCommandExecutor.java:128)
>> at
>> org.apache.geronimo.gshell.ExecutingVisitor.visit
>> (ExecutingVisitor.java:96)
>> at
>> org.apache.geronimo.gshell.parser.ASTExpression.jjtAccept
>> (ASTExpression.java:17)
>> at
>> org.apache.geronimo.gshell.parser.SimpleNode.childrenAccept
>> (SimpleNode.java:57)
>> at
>> org.apache.geronimo.gshell.ExecutingVisitor.visit
>> (ExecutingVisitor.java:79)
>> at
>> org.apache.geronimo.gshell.parser.ASTCommandLine.jjtAccept
>> (ASTCommandLine.java:17)
>> at
>> org.apache.geronimo.gshell.DefaultCommandLineBuilder$1.execute
>> (DefaultCommandLineBuilder.java:95)
>> at
>> org.apache.geronimo.gshell.DefaultCommandExecutor.execute
>> (DefaultCommandExecutor.java:72)
>> at
>> org.apache.geronimo.gshell.DefaultShell.execute(DefaultShell.java:
>> 120)
>> at
>> org.apache.geronimo.gshell.DefaultShell$1.execute
>> (DefaultShell.java:152)
>> at org.apache.geronimo.gshell.console.Console.work
>> (Console.java:187)
>> at org.apache.geronimo.gshell.console.Console.run
>> (Console.java:128)
>> at
>> org.apache.geronimo.gshell.console.JLineConsole.run
>> (JLineConsole.java:68)
>> at
>> org.apache.geronimo.gshell.DefaultShell.run(DefaultShell.java:213)
>> at org.apache.geronimo.gshell.GShell.run(GShell.java:156)
>> at org.apache.geronimo.gshell.cli.Main.boot(Main.java:247)
>> at org.apache.geronimo.gshell.cli.Main.main(Main.java:264)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke
>> (NativeMethodAccessorImpl.java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke
>> (DelegatingMethodAccessorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:585)
>> at
>> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced
>> (Launcher.java:289)
>> at
>> org.codehaus.plexus.classworlds.launcher.Launcher.launch
>> (Launcher.java:229)
>> at
>> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode
>> (Launcher.java:408)
>> at
>> org.codehaus.plexus.classworlds.launcher.Launcher.main
>> (Launcher.java:351)
>> at
>> org.apache.geronimo.gshell.bootstrap.Launcher.main(Launcher.java:59)
>> Caused by:
>> org.codehaus.plexus.component.factory.ComponentInstantiationException
>> :
>> Could not instantiate component: role:
>> 'org.apache.geronimo.gshell.command.Command', implementation:
>> 'org.apache.geronimo.gshell.remote.client.SshCommand', role hint:
>> 'ssh'
>> realm: gshell:fbf112fb-ba13-49ee-8221-17608088e507
>> at
>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.makeE
>> xception(JavaComponentFactory.java:113)
>> at
>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newIn
>> stance(JavaComponentFactory.java:87)
>> at
>> org.codehaus.plexus.component.manager.AbstractComponentManager.create
>> ComponentInstance(AbstractComponentManager.java:239)
>> at
>> org.codehaus.plexus.component.manager.AbstractComponentManager.create
>> ComponentInstance(AbstractComponentManager.java:128)
>> at
>> org.codehaus.plexus.component.manager.PerLookupComponentManager.getCo
>> mponent(PerLookupComponentManager.java:40)
>> at
>> org.codehaus.plexus.DefaultComponentLookupManager.lookup
>> (DefaultComponentLookupManager.java:147)
>> ... 32 more
>> Caused by: java.lang.NoClassDefFoundError: com/jcraft/jsch/UserInfo
>> at java.lang.Class.getDeclaredConstructors0(Native Method)
>> at java.lang.Class.privateGetDeclaredConstructors
>> (Class.java:2328)
>> at java.lang.Class.getConstructor0(Class.java:2640)
>> at java.lang.Class.newInstance0(Class.java:321)
>> at java.lang.Class.newInstance(Class.java:303)
>> at
>> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newIn
>> stance(JavaComponentFactory.java:66)
>> ... 36 more
>> treimann@daffy.local:/>
>>
>>
>> Thanks,
>> -Ken
>>
>>
>>
>> Jason Warner wrote:
>>> Ken,
>>>
>>> I am such a dork. I've been sitting here putzing around wishing for
>>> more information. Can you run GShell using the debug command?
>>> "./gsh
>>> --debug" I think. This should give a full stack trace for that
>>> error.
>>> Can you please post that stack trace?
>>>
>>> Thanks!
>>>
>>> Jason Warner.
>>>
>>
>>> On Nov 6, 2007 10:20 PM, Ken Treimann <kctreima at sign ncsu
>>> period edu> wrote:
>>>
>>>> Yes, when I run the new ssh command. Sorry for the confusion!
>>>>
>>>> Thanks,
>>>> -Ken
>>>>
>>>>
>>>> Jason Warner wrote:
>>>>
>>>>> Hi Ken,
>>>>>
>>>>> I'm a little confused by the order of events that transpired here.
>>>>> When do you get this error? When you try to run the command?
>>>>>
>>>>>
>>>>> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu
>>>>> period edu> wrote:
>>>>>
>>>>>
>>>>>> Hello,
>>>>>>
>>>>>> I am attempting to implement this functionality for
>>>>>> contribution, but am
>>>>>> running into this issue:
>>>>>>
>>>>>> ERROR ComponentLookupException: Unable to lookup component
>>>>>> 'org.apache.geronimo.gshell.command.Command', it could not be
>>>>>> created
>>>>>>
>>>>>> Basically I copied RshCommand, and created a secure channel by
>>>>>> adding a
>>>>>> port forwarder using the PortForwardingL example from JSch. In my
>>>>>> initial investigation, I copied RshCommand, made no changes
>>>>>> other than
>>>>>> the class name and command ID, ran it, and it successfully
>>>>>> opened an rsh
>>>>>> to a rsh-server. After adding the port forwarder, a UserInfo
>>>>>> helper
>>>>>> class used by the JSch session, and command-line options for
>>>>>> the ssh
>>>>>> user and password, I get the error. I tried to undo everything
>>>>>> I did to
>>>>>> return to what previously worked, but I still get the error.
>>>>>> There is
>>>>>> some fundamental GShell-ness that I'm missing here, so can
>>>>>> anyone give
>>>>>> me a clue where I should start?
>>>>>>
>>>>>>
>>>>>> Thanks,
>>>>>> -Ken
>>>>>>
>>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Warner <ja...@gmail.com>.
Ken,
I'm not sure if this is a good way to do it or not, but try adding the
dependency to gshell/trunk/gshell-assembly/pom.xml. I'm curious to
see what happens.
~Jason Warner
On Nov 6, 2007 11:03 PM, Ken Treimann <kc...@ncsu.edu> wrote:
> Jason,
>
> Looks like it's having trouble finding JSch. I added jsch-0.1.36.jar to
> the Maven repository using mvn install:install-file, and added a
> dependency to pom.xml for each of gshell-remote-client and
> gshell-remote-common where it's used (it wouldn't even build until I had
> done this). What did I miss?
>
> Here's the stack trace in case there's anything I didn't see:
>
> treimann@daffy.local:/> ssh tcp://192.168.1.13:3000
> INFO DefaultCommandExecutor [main] Executing (String): ssh
> tcp://192.168.1.13:3000
> DEBUG DefaultCommandLineBuilder [main] CommandLine
> (org.apache.geronimo.gshell.parser.ASTCommandLine)
> DEBUG DefaultCommandLineBuilder [main] Expression
> (org.apache.geronimo.gshell.parser.ASTExpression)
> DEBUG DefaultCommandLineBuilder [main] PlainString( ssh )
> (org.apache.geronimo.gshell.parser.ASTPlainString)
> DEBUG DefaultCommandLineBuilder [main] PlainString(
> tcp://192.168.1.13:3000 ) (org.apache.geronimo.gshell.parser.ASTPlainString)
> INFO DefaultCommandExecutor [main] Executing (ssh):
> [tcp://192.168.1.13:3000]
> DEBUG DefaultLayoutManager [main] Searching for command for path: ssh
> DEBUG PlexusCommandWrapper [main] Child container realm:
> gshell:fbf112fb-ba13-49ee-8221-17608088e507
> ERROR ComponentLookupException: Unable to lookup component
> 'org.apache.geronimo.gshell.command.Command', it could not be created
> DEBUG DefaultShell [main]
> org.codehaus.plexus.component.repository.exception.ComponentLookupException:
> Unable to lookup component 'org.apache.geronimo.gshell.command.Command',
> it could not be created
> org.codehaus.plexus.component.repository.exception.ComponentLookupException:
> Unable to lookup component 'org.apache.geronimo.gshell.command.Command',
> it could not be created
> at
> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:151)
> at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:500)
> at
> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:133)
> at
> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:91)
> at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:549)
> at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:543)
> at
> org.apache.geronimo.gshell.plugin.PlexusCommandWrapper.execute(PlexusCommandWrapper.java:66)
> at
> org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:128)
> at
> org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:96)
> at
> org.apache.geronimo.gshell.parser.ASTExpression.jjtAccept(ASTExpression.java:17)
> at
> org.apache.geronimo.gshell.parser.SimpleNode.childrenAccept(SimpleNode.java:57)
> at
> org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:79)
> at
> org.apache.geronimo.gshell.parser.ASTCommandLine.jjtAccept(ASTCommandLine.java:17)
> at
> org.apache.geronimo.gshell.DefaultCommandLineBuilder$1.execute(DefaultCommandLineBuilder.java:95)
> at
> org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:72)
> at
> org.apache.geronimo.gshell.DefaultShell.execute(DefaultShell.java:120)
> at
> org.apache.geronimo.gshell.DefaultShell$1.execute(DefaultShell.java:152)
> at org.apache.geronimo.gshell.console.Console.work(Console.java:187)
> at org.apache.geronimo.gshell.console.Console.run(Console.java:128)
> at
> org.apache.geronimo.gshell.console.JLineConsole.run(JLineConsole.java:68)
> at
> org.apache.geronimo.gshell.DefaultShell.run(DefaultShell.java:213)
> at org.apache.geronimo.gshell.GShell.run(GShell.java:156)
> at org.apache.geronimo.gshell.cli.Main.boot(Main.java:247)
> at org.apache.geronimo.gshell.cli.Main.main(Main.java:264)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:408)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:351)
> at
> org.apache.geronimo.gshell.bootstrap.Launcher.main(Launcher.java:59)
> Caused by:
> org.codehaus.plexus.component.factory.ComponentInstantiationException:
> Could not instantiate component: role:
> 'org.apache.geronimo.gshell.command.Command', implementation:
> 'org.apache.geronimo.gshell.remote.client.SshCommand', role hint: 'ssh'
> realm: gshell:fbf112fb-ba13-49ee-8221-17608088e507
> at
> org.codehaus.plexus.component.factory.java.JavaComponentFactory.makeException(JavaComponentFactory.java:113)
> at
> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:87)
> at
> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:239)
> at
> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:128)
> at
> org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:40)
> at
> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
> ... 32 more
> Caused by: java.lang.NoClassDefFoundError: com/jcraft/jsch/UserInfo
> at java.lang.Class.getDeclaredConstructors0(Native Method)
> at java.lang.Class.privateGetDeclaredConstructors(Class.java:2328)
> at java.lang.Class.getConstructor0(Class.java:2640)
> at java.lang.Class.newInstance0(Class.java:321)
> at java.lang.Class.newInstance(Class.java:303)
> at
> org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:66)
> ... 36 more
> treimann@daffy.local:/>
>
>
> Thanks,
> -Ken
>
>
>
> Jason Warner wrote:
> > Ken,
> >
> > I am such a dork. I've been sitting here putzing around wishing for
> > more information. Can you run GShell using the debug command? "./gsh
> > --debug" I think. This should give a full stack trace for that error.
> > Can you please post that stack trace?
> >
> > Thanks!
> >
> > Jason Warner.
> >
>
> > On Nov 6, 2007 10:20 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
> >
> >> Yes, when I run the new ssh command. Sorry for the confusion!
> >>
> >> Thanks,
> >> -Ken
> >>
> >>
> >> Jason Warner wrote:
> >>
> >>> Hi Ken,
> >>>
> >>> I'm a little confused by the order of events that transpired here.
> >>> When do you get this error? When you try to run the command?
> >>>
> >>>
> >>> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
> >>>
> >>>
> >>>> Hello,
> >>>>
> >>>> I am attempting to implement this functionality for contribution, but am
> >>>> running into this issue:
> >>>>
> >>>> ERROR ComponentLookupException: Unable to lookup component
> >>>> 'org.apache.geronimo.gshell.command.Command', it could not be created
> >>>>
> >>>> Basically I copied RshCommand, and created a secure channel by adding a
> >>>> port forwarder using the PortForwardingL example from JSch. In my
> >>>> initial investigation, I copied RshCommand, made no changes other than
> >>>> the class name and command ID, ran it, and it successfully opened an rsh
> >>>> to a rsh-server. After adding the port forwarder, a UserInfo helper
> >>>> class used by the JSch session, and command-line options for the ssh
> >>>> user and password, I get the error. I tried to undo everything I did to
> >>>> return to what previously worked, but I still get the error. There is
> >>>> some fundamental GShell-ness that I'm missing here, so can anyone give
> >>>> me a clue where I should start?
> >>>>
> >>>>
> >>>> Thanks,
> >>>> -Ken
> >>>>
>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Ken Treimann <kc...@ncsu.edu>.
Jason,
Looks like it's having trouble finding JSch. I added jsch-0.1.36.jar to
the Maven repository using mvn install:install-file, and added a
dependency to pom.xml for each of gshell-remote-client and
gshell-remote-common where it's used (it wouldn't even build until I had
done this). What did I miss?
Here's the stack trace in case there's anything I didn't see:
treimann@daffy.local:/> ssh tcp://192.168.1.13:3000
INFO DefaultCommandExecutor [main] Executing (String): ssh
tcp://192.168.1.13:3000
DEBUG DefaultCommandLineBuilder [main] CommandLine
(org.apache.geronimo.gshell.parser.ASTCommandLine)
DEBUG DefaultCommandLineBuilder [main] Expression
(org.apache.geronimo.gshell.parser.ASTExpression)
DEBUG DefaultCommandLineBuilder [main] PlainString( ssh )
(org.apache.geronimo.gshell.parser.ASTPlainString)
DEBUG DefaultCommandLineBuilder [main] PlainString(
tcp://192.168.1.13:3000 ) (org.apache.geronimo.gshell.parser.ASTPlainString)
INFO DefaultCommandExecutor [main] Executing (ssh):
[tcp://192.168.1.13:3000]
DEBUG DefaultLayoutManager [main] Searching for command for path: ssh
DEBUG PlexusCommandWrapper [main] Child container realm:
gshell:fbf112fb-ba13-49ee-8221-17608088e507
ERROR ComponentLookupException: Unable to lookup component
'org.apache.geronimo.gshell.command.Command', it could not be created
DEBUG DefaultShell [main]
org.codehaus.plexus.component.repository.exception.ComponentLookupException:
Unable to lookup component 'org.apache.geronimo.gshell.command.Command',
it could not be created
org.codehaus.plexus.component.repository.exception.ComponentLookupException:
Unable to lookup component 'org.apache.geronimo.gshell.command.Command',
it could not be created
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:151)
at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:500)
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:133)
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:91)
at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:549)
at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:543)
at
org.apache.geronimo.gshell.plugin.PlexusCommandWrapper.execute(PlexusCommandWrapper.java:66)
at
org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:128)
at
org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:96)
at
org.apache.geronimo.gshell.parser.ASTExpression.jjtAccept(ASTExpression.java:17)
at
org.apache.geronimo.gshell.parser.SimpleNode.childrenAccept(SimpleNode.java:57)
at
org.apache.geronimo.gshell.ExecutingVisitor.visit(ExecutingVisitor.java:79)
at
org.apache.geronimo.gshell.parser.ASTCommandLine.jjtAccept(ASTCommandLine.java:17)
at
org.apache.geronimo.gshell.DefaultCommandLineBuilder$1.execute(DefaultCommandLineBuilder.java:95)
at
org.apache.geronimo.gshell.DefaultCommandExecutor.execute(DefaultCommandExecutor.java:72)
at
org.apache.geronimo.gshell.DefaultShell.execute(DefaultShell.java:120)
at
org.apache.geronimo.gshell.DefaultShell$1.execute(DefaultShell.java:152)
at org.apache.geronimo.gshell.console.Console.work(Console.java:187)
at org.apache.geronimo.gshell.console.Console.run(Console.java:128)
at
org.apache.geronimo.gshell.console.JLineConsole.run(JLineConsole.java:68)
at
org.apache.geronimo.gshell.DefaultShell.run(DefaultShell.java:213)
at org.apache.geronimo.gshell.GShell.run(GShell.java:156)
at org.apache.geronimo.gshell.cli.Main.boot(Main.java:247)
at org.apache.geronimo.gshell.cli.Main.main(Main.java:264)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at
org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:408)
at
org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:351)
at
org.apache.geronimo.gshell.bootstrap.Launcher.main(Launcher.java:59)
Caused by:
org.codehaus.plexus.component.factory.ComponentInstantiationException:
Could not instantiate component: role:
'org.apache.geronimo.gshell.command.Command', implementation:
'org.apache.geronimo.gshell.remote.client.SshCommand', role hint: 'ssh'
realm: gshell:fbf112fb-ba13-49ee-8221-17608088e507
at
org.codehaus.plexus.component.factory.java.JavaComponentFactory.makeException(JavaComponentFactory.java:113)
at
org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:87)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:239)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:128)
at
org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:40)
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
... 32 more
Caused by: java.lang.NoClassDefFoundError: com/jcraft/jsch/UserInfo
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2328)
at java.lang.Class.getConstructor0(Class.java:2640)
at java.lang.Class.newInstance0(Class.java:321)
at java.lang.Class.newInstance(Class.java:303)
at
org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:66)
... 36 more
treimann@daffy.local:/>
Thanks,
-Ken
Jason Warner wrote:
> Ken,
>
> I am such a dork. I've been sitting here putzing around wishing for
> more information. Can you run GShell using the debug command? "./gsh
> --debug" I think. This should give a full stack trace for that error.
> Can you please post that stack trace?
>
> Thanks!
>
> Jason Warner.
>
> On Nov 6, 2007 10:20 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
>
>> Yes, when I run the new ssh command. Sorry for the confusion!
>>
>> Thanks,
>> -Ken
>>
>>
>> Jason Warner wrote:
>>
>>> Hi Ken,
>>>
>>> I'm a little confused by the order of events that transpired here.
>>> When do you get this error? When you try to run the command?
>>>
>>>
>>> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
>>>
>>>
>>>> Hello,
>>>>
>>>> I am attempting to implement this functionality for contribution, but am
>>>> running into this issue:
>>>>
>>>> ERROR ComponentLookupException: Unable to lookup component
>>>> 'org.apache.geronimo.gshell.command.Command', it could not be created
>>>>
>>>> Basically I copied RshCommand, and created a secure channel by adding a
>>>> port forwarder using the PortForwardingL example from JSch. In my
>>>> initial investigation, I copied RshCommand, made no changes other than
>>>> the class name and command ID, ran it, and it successfully opened an rsh
>>>> to a rsh-server. After adding the port forwarder, a UserInfo helper
>>>> class used by the JSch session, and command-line options for the ssh
>>>> user and password, I get the error. I tried to undo everything I did to
>>>> return to what previously worked, but I still get the error. There is
>>>> some fundamental GShell-ness that I'm missing here, so can anyone give
>>>> me a clue where I should start?
>>>>
>>>>
>>>> Thanks,
>>>> -Ken
>>>>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Warner <ja...@gmail.com>.
Sorry, Ken. I reread that and it seemed a little confusing. Launch
GShell using "./gsh --debug" (or the windows equivalent) and then run
the command that causes that error. Please post the resultant stack
trace.
Thanks again.
Jason Warner
On Nov 6, 2007 10:37 PM, Jason Warner <ja...@gmail.com> wrote:
> Ken,
>
> I am such a dork. I've been sitting here putzing around wishing for
> more information. Can you run GShell using the debug command? "./gsh
> --debug" I think. This should give a full stack trace for that error.
> Can you please post that stack trace?
>
> Thanks!
>
> Jason Warner.
>
>
> On Nov 6, 2007 10:20 PM, Ken Treimann <kc...@ncsu.edu> wrote:
> > Yes, when I run the new ssh command. Sorry for the confusion!
> >
> > Thanks,
> > -Ken
> >
> >
> > Jason Warner wrote:
> > > Hi Ken,
> > >
> > > I'm a little confused by the order of events that transpired here.
> > > When do you get this error? When you try to run the command?
> > >
> >
> > > On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
> > >
> > >> Hello,
> > >>
> > >> I am attempting to implement this functionality for contribution, but am
> > >> running into this issue:
> > >>
> > >> ERROR ComponentLookupException: Unable to lookup component
> > >> 'org.apache.geronimo.gshell.command.Command', it could not be created
> > >>
> > >> Basically I copied RshCommand, and created a secure channel by adding a
> > >> port forwarder using the PortForwardingL example from JSch. In my
> > >> initial investigation, I copied RshCommand, made no changes other than
> > >> the class name and command ID, ran it, and it successfully opened an rsh
> > >> to a rsh-server. After adding the port forwarder, a UserInfo helper
> > >> class used by the JSch session, and command-line options for the ssh
> > >> user and password, I get the error. I tried to undo everything I did to
> > >> return to what previously worked, but I still get the error. There is
> > >> some fundamental GShell-ness that I'm missing here, so can anyone give
> > >> me a clue where I should start?
> > >>
> > >>
> > >> Thanks,
> > >> -Ken
> > >>
> >
>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Warner <ja...@gmail.com>.
Ken,
I am such a dork. I've been sitting here putzing around wishing for
more information. Can you run GShell using the debug command? "./gsh
--debug" I think. This should give a full stack trace for that error.
Can you please post that stack trace?
Thanks!
Jason Warner.
On Nov 6, 2007 10:20 PM, Ken Treimann <kc...@ncsu.edu> wrote:
> Yes, when I run the new ssh command. Sorry for the confusion!
>
> Thanks,
> -Ken
>
>
> Jason Warner wrote:
> > Hi Ken,
> >
> > I'm a little confused by the order of events that transpired here.
> > When do you get this error? When you try to run the command?
> >
>
> > On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
> >
> >> Hello,
> >>
> >> I am attempting to implement this functionality for contribution, but am
> >> running into this issue:
> >>
> >> ERROR ComponentLookupException: Unable to lookup component
> >> 'org.apache.geronimo.gshell.command.Command', it could not be created
> >>
> >> Basically I copied RshCommand, and created a secure channel by adding a
> >> port forwarder using the PortForwardingL example from JSch. In my
> >> initial investigation, I copied RshCommand, made no changes other than
> >> the class name and command ID, ran it, and it successfully opened an rsh
> >> to a rsh-server. After adding the port forwarder, a UserInfo helper
> >> class used by the JSch session, and command-line options for the ssh
> >> user and password, I get the error. I tried to undo everything I did to
> >> return to what previously worked, but I still get the error. There is
> >> some fundamental GShell-ness that I'm missing here, so can anyone give
> >> me a clue where I should start?
> >>
> >>
> >> Thanks,
> >> -Ken
> >>
>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Ken Treimann <kc...@ncsu.edu>.
Yes, when I run the new ssh command. Sorry for the confusion!
Thanks,
-Ken
Jason Warner wrote:
> Hi Ken,
>
> I'm a little confused by the order of events that transpired here.
> When do you get this error? When you try to run the command?
>
> On Nov 6, 2007 9:51 PM, Ken Treimann <kctreima at sign ncsu period edu> wrote:
>
>> Hello,
>>
>> I am attempting to implement this functionality for contribution, but am
>> running into this issue:
>>
>> ERROR ComponentLookupException: Unable to lookup component
>> 'org.apache.geronimo.gshell.command.Command', it could not be created
>>
>> Basically I copied RshCommand, and created a secure channel by adding a
>> port forwarder using the PortForwardingL example from JSch. In my
>> initial investigation, I copied RshCommand, made no changes other than
>> the class name and command ID, ran it, and it successfully opened an rsh
>> to a rsh-server. After adding the port forwarder, a UserInfo helper
>> class used by the JSch session, and command-line options for the ssh
>> user and password, I get the error. I tried to undo everything I did to
>> return to what previously worked, but I still get the error. There is
>> some fundamental GShell-ness that I'm missing here, so can anyone give
>> me a clue where I should start?
>>
>>
>> Thanks,
>> -Ken
>>
Re: Trying to implement GShell ssh command (jira issue GSHELL-16)
Posted by Jason Warner <ja...@gmail.com>.
Hi Ken,
I'm a little confused by the order of events that transpired here.
When do you get this error? When you try to run the command?
On Nov 6, 2007 9:51 PM, Ken Treimann <kc...@ncsu.edu> wrote:
> Hello,
>
> I am attempting to implement this functionality for contribution, but am
> running into this issue:
>
> ERROR ComponentLookupException: Unable to lookup component
> 'org.apache.geronimo.gshell.command.Command', it could not be created
>
> Basically I copied RshCommand, and created a secure channel by adding a
> port forwarder using the PortForwardingL example from JSch. In my
> initial investigation, I copied RshCommand, made no changes other than
> the class name and command ID, ran it, and it successfully opened an rsh
> to a rsh-server. After adding the port forwarder, a UserInfo helper
> class used by the JSch session, and command-line options for the ssh
> user and password, I get the error. I tried to undo everything I did to
> return to what previously worked, but I still get the error. There is
> some fundamental GShell-ness that I'm missing here, so can anyone give
> me a clue where I should start?
>
>
> Thanks,
> -Ken
>