You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by "webmaster@oredelmondo.it" <we...@oredelmondo.it> on 2005/05/10 14:58:54 UTC
Re: Changing port PERFECT!
*Thanks Vincenzo, it works now.
it was a formatting error.
Thanks again*
Vincenzo Gianferrari Pini wrote:
> You are getting an XML parsing error. It may be that "<!---->" should
> be replaced by "<!-- -->". If not, check the syntax character by
> character.
>
> Unrelated to the error: I would use <smtpserver-2> or <smtpserver-bis>
> or something else instead of <smtpserver-tls>, just for cleanness.
>
> Vincenzo
>
> webmaster@oredelmondo.it wrote:
>
>> Vincenzo Gianferrari Pini wrote:
>>
>>> Another way is not to use port forwarding and have james listen on
>>> port 25 *and any other ports*.
>>>
>>> To do that, have a look at http://wiki.apache.org/james/UsingSSL -
>>> section "James setup example for SMTPS", with the following
>>> differences (to ignore ssl specific stuff):
>>>
>>> 1) set <useTLS>false</useTLS>
>>>
>>> 2) ignore the discussion about <factory name="ssl" ...> entry
>>>
>>> 3) I suggest not to use port 465 nor the name "smtpserver-tls" to
>>> avoid confusion.
>>>
>>> You can do the same things with POP3.
>>>
>>> Vincenzo
>>
>>
>>
>> Thanks for responding,
>> It seems a easy solution,
>> I only added the foollowing code to the files, but I got an exception
>> reported below:
>> May you help to undestood what happened?
>> *
>> Thanks
>>
>> config.xml:
>> * <!-- The SMTP-TLS server is enabled by default -->
>> <!-- Disabling blocks will stop them from listening, -->
>> <!-- but does not free as many resources as removing them would -->
>> <smtpserver-tls>
>> <!-- port 25 is the well-known/IANA registered port for SMTP -->
>> <port>26</port>
>>
>> <!-- Uncomment this if you want to bind to a specific
>> inetaddress -->
>> <!--
>> <bind> </bind>
>> -->
>> <!-- Uncomment this if you want to use TLS (SSL) on this port -->
>> <!---->
>> <useTLS>false</useTLS>
>> <handler>
>> <!-- This is the name used by the server to identify itself
>> in the SMTP -->
>> <!-- protocol. If autodetect is TRUE, the server will
>> discover its -->
>> <!-- own host name and use that in the protocol. If
>> discovery fails, -->
>> <!-- the value of 'localhost' is used. If autodetect is
>> FALSE, James -->
>> <!-- will use the specified value. -->
>> <helloName>myMailServer</helloName>
>> <connectiontimeout>360000</connectiontimeout>
>>
>> <!-- Uncomment this if you want to require SMTP
>> authentication. -->
>> <!--
>> <authRequired>true</authRequired>
>> -->
>>
>> <!-- CHECKME! -->
>> <!-- Uncomment this if you want to authorize specific
>> addresses/networks.
>> If you use SMTP AUTH, addresses that match those
>> specified here will
>> be permitted to relay without SMTP AUTH. If you do not
>> use SMTP
>> AUTH, and you specify addreses here, then only
>> addresses that match
>> those specified will be permitted to relay.
>>
>> Addresses may be specified as a an IP address or domain
>> name, with an
>> optional netmask, e.g.,
>>
>> 127.*, 127.0.0.0/8, 127.0.0.0/255.0.0.0, and
>> localhost/8 are all the same
>>
>> See also the RemoteAddrNotInNetwork matcher in the
>> transport processor.
>> You would generally use one OR the other approach.
>> -->
>> <authorizedAddresses>127.0.0.0/8</authorizedAddresses>
>>
>> <!-- Uncomment this if you want to verify sender addresses,
>> ensuring that -->
>> <!-- the sender address matches the user who has
>> authenticated. -->
>> <!-- This prevents a user of your mail server from acting as
>> someone else -->
>> <!--
>> <verifyIdentity>true</verifyIdentity>
>> -->
>>
>> <!-- This sets the maximum allowed message size (in
>> kilobytes) for this -->
>> <!-- SMTP service. If unspecified, the value defaults to 0,
>> which means no limit. -->
>> <maxmessagesize>0</maxmessagesize>
>> </handler>
>> </smtpserver-tls>
>>
>> *assembly.xml
>> * <!-- SMTP-TLS Server -->
>> <block name="smtpserver-tls"
>> class="org.apache.james.smtpserver.SMTPServer" >
>> <provide name="James" role="org.apache.mailet.MailetContext"/>
>> <provide name="mailstore"
>> role="org.apache.james.services.MailStore"/>
>> <provide name="users-store"
>> role="org.apache.james.services.UsersStore"/>
>> <provide name="sockets"
>>
>> role="org.apache.avalon.cornerstone.services.sockets.SocketManager"/>
>> <provide name="connections"
>> role="org.apache.james.services.JamesConnectionManager"/>
>> <provide name="James" role="org.apache.james.services.MailServer"/>
>> <provide name="thread-manager"
>>
>> role="org.apache.avalon.cornerstone.services.threads.ThreadManager" />
>> </block>
>>
>> *environment.xml*
>> <category name="smtpserver-tls" log-level="INFO">
>> <log-target id-ref="smtpserver-target"/>
>> </category> *
>> here the exception from the console*
>> ---------------------------------------------------------
>> --- Message ---
>> Error building configuration from
>> file:/D:/james-2.2.0/apps/james/SAR-INF/config.xml.
>> --- Stack Trace ---
>> org.apache.avalon.phoenix.interfaces.DeploymentException: Error
>> building configuration from file:/D:/jam
>> es-2.2.0/apps/james/SAR-INF/config.xml.
>> at
>> org.apache.avalon.phoenix.components.deployer.DefaultDeployer.getConfigurationFor(DefaultDepl
>>
>> oyer.java:499)
>> at
>> org.apache.avalon.phoenix.components.deployer.DefaultDeployer.deploy(DefaultDeployer.java:325
>>
>> )
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFile(DefaultEmbeddor.java
>>
>> :498)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFile(DefaultEmbeddor.java
>>
>> :491)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFiles(DefaultEmbeddor.jav
>>
>> a:476)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployDefaultApplications(Defau
>>
>> ltEmbeddor.java:466)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.execute(DefaultEmbeddor.java:22
>>
>> 4)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.run(CLIMain.java:158)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.execute(CLIMain.java:144)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.main(CLIMain.java:102)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
>> Source)
>> at java.lang.reflect.Method.invoke(Unknown Source)
>> at org.apache.avalon.phoenix.launcher.Main.startup(Main.java:94)
>> at org.apache.avalon.phoenix.launcher.Main.main(Main.java:46)
>> Caused by: org.xml.sax.SAXParseException: Attribute "class" was
>> already specified for element "accounts"
>> .
>> at
>> org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1183)
>>
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:129)
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:116)
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:97)
>> at
>> org.apache.avalon.phoenix.components.deployer.DefaultDeployer.getConfigurationFor(DefaultDepl
>>
>> oyer.java:493)
>> ... 15 more
>> rethrown from
>> org.xml.sax.SAXParseException: Attribute "class" was already
>> specified for element "accounts".
>> at
>> org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1183)
>>
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:129)
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:116)
>> at
>> org.apache.avalon.phoenix.tools.configuration.ConfigurationBuilder.build(ConfigurationBuilder
>>
>> .java:97)
>> at
>> org.apache.avalon.phoenix.components.deployer.DefaultDeployer.getConfigurationFor(DefaultDepl
>>
>> oyer.java:493)
>> at
>> org.apache.avalon.phoenix.components.deployer.DefaultDeployer.deploy(DefaultDeployer.java:325
>>
>> )
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFile(DefaultEmbeddor.java
>>
>> :498)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFile(DefaultEmbeddor.java
>>
>> :491)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployFiles(DefaultEmbeddor.jav
>>
>> a:476)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.deployDefaultApplications(Defau
>>
>> ltEmbeddor.java:466)
>> at
>> org.apache.avalon.phoenix.components.embeddor.DefaultEmbeddor.execute(DefaultEmbeddor.java:22
>>
>> 4)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.run(CLIMain.java:158)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.execute(CLIMain.java:144)
>> at
>> org.apache.avalon.phoenix.frontends.CLIMain.main(CLIMain.java:102)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
>> Source)
>> at java.lang.reflect.Method.invoke(Unknown Source)
>> at org.apache.avalon.phoenix.launcher.Main.startup(Main.java:94)
>> at org.apache.avalon.phoenix.launcher.Main.main(Main.java:46)
>>
>> ---------------------------------------------------------
>> The log file may contain further details of error.
>> Please check the configuration files and restart Phoenix.
>> If the problem persists, contact the Avalon project. See
>> http://jakarta.apache.org/avalon for more information.
>> Shutting down Phoenix.
>> D:\james-2.2.0\bin>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>
>