Apache Archiva file upload size - repository

If I upload an artifact (~23MB file size) in Apache-Archiva 2.2.1, I get an upload-error in the UI:
fileupload.errors.Request Entity Too Large
This occurs also with mvn deploy:
Return code is: 413, ReasonPhrase: Request Entity Too Large
Archiva is running on tomcat 9.0.0.M21, deployed as war.
So, how can I increase the upload file size limit in apache archiva? I can't find any appropriate properties to set in archiva.xml.

So finally i could resolve this problem. It was not an Archiva setting, increasing the upload size in nginx.conf to client_max_body_size 64M; fixed it (Tomcat is running behind a SSL-Proxy).
Thx for watching.

Related

Docker Rocket chat Rest api upload file error 413 Entity too large

I am using rocket chat rest API, every thing works good, but when i upload file to rocket chat rest api, it shows error 413 Request Entity Too Large, but when i upload file from website it uploaded any size of fie.
After checking all scenario, I concluded that file size less than and equal to 1 mb is uploaded successfully, and greater than 1 MB shows this error 413 Request Entity Too Large.
I upload file from post man using this url
https://rocket.chat.url/api/v1/rooms.upload/RoomId
Headers:
Content-Type:application/x-www-form-urlencoded
X-Auth-Token:User-Token
X-User-Id:User-Id
Form-Data:
file - selected file
Html result Error
<html>
<head><title>413 Request Entity Too Large</title></head>
<body bgcolor="white">
<center><h1>413 Request Entity Too Large</h1></center>
<hr><center>nginx/1.10.3 (Ubuntu)</center>
</body>
</html>
when File successfully insert it shows following.
{
"success": true
}
After checking many scenarios and search many urls i get solution from this.
I have used rocket chat docker and I append one line to nginx config file.
Solution:
login to ubuntu server
write sudo nano /etc/nginx/nginx.conf and hit enter
Add or update client_max_body_size in
http {
client_max_body_size 8M; #used your exceeded limit instead of 8M
#other lines...
}
Restart nginx by command service nginx restart or systemctl restart nginx
Uploading larger file again, and it is successful.

Glassfish 5 error: GRIZZLY0205 Post too large

GF5 build1, Java EE7 + Primefaces 6.1, trying to upload photo ~ 2MB in p:textEditor componnent I always get error:
Severe: java.lang.IllegalStateException: GRIZZLY0205: Post too large
Setting "Max Post Size" to -1 or any >1mljn value in Configurations - server config - Network Config - Network Listeners - http-listener-1 doesn't help. The same on GF 4.1
This is a x-www-form-url encoded content so we need set parameter: max-form-post-size. This isn't exposed via the UI, but you can configure it using cmd:
asadmin set configs.config.server-config.network-config.protocols.protocol.http-listener-1.http.max-form-post-size-bytes=-1

KEYCLOAK unknown authenticator error - Client Adapter installed

I am trying to setup Keycloak with Tomcat 8.
I followed the instruction carefully. I downloaded the Client Adapter for Tomcat8 and copied all the jar into $CATALINA_HOME/lib directory. I modified my web.xml login-config to use KEYCLOAK. Yet when I started Tomcat I kept getting Severe Error Unknown Authenticator??
Anywhere I googled everyone said you have to install the Client Adapter but.. in my case IT IS ALREADY THERE!!! HELP!!
I think you forgot to create a META-INF directory beside the WEB-INF and put a file named context.xml into it:
The contents of this file has to be
<?xml version="1.0" encoding="UTF-8"?>
<Context>
<Valve className="org.keycloak.adapters.tomcat.KeycloakAuthenticatorValve"/>
</Context>
This is not needed if you deploy the war into WildFly. I had the same problem when I tried to transfer a well working webApp from WildFly to Tomcat.

Log is not loading in to new catalina.out file

we are using tomcat server to our application . Here very much log creating into catalina.out . we want to make archive of catalina.out . then deleted old catalina.out file . and created a new catalina.out file and given permissions .
But the new log is not loading in to catalina.out file .
After restarting tomcat server , it started to load log in to catalina.out file .
But ,We want achieve this with out down time .
Thanks,
Srinivas
You can configure Tomcat Logging either with JULI or Log4j.
Take a look at some configuration examples.
If you choose to use log4j with Tomcat, pay attention to these configuration attributes
# Max file size, after which the logfile is rolled and indexed
log4j.appender.R.MaxFileSize=10MB
# Number of backup indexed log files.
log4j.appender.R.MaxBackupIndex=10
In Apache Log4j Extras you can find log file appenders that support archiving.

Redeploy an existing Axis2 web service in remote server

I am trying to redeploy an Axis2 web service in a remote server. I am doing this by uploading the .aar file from the axis2 admin console.
I know 'hot update' is disabled by default. So I tried adding the following line to the services.xml file:
<parameter name="hotdeployment" >true</parameter>
<parameter name="hotupdate" >true</parameter>
However, the redeployment was not successful.
I also dont have permission to restart the server.
Can anyone let me know the right way to do this ?
Thanks!
This settings located in axis2.xml, You should set there.
Standalone Axis2 server:
$AXIS_HOME/conf/axis2.xml
In war file:
WEB-INF/conf/axis2.xml