java.net.SocketTimeoutException Read timed out

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
Post Reply
rickygm
Posts: 19
Joined: Sat Sep 13, 2014 1:48 am

java.net.SocketTimeoutException Read timed out

Post by rickygm »

Hi , someone has happened the following in an account migration, I am restoring the backup of an account on another server and it shows me this message: ERROR: zclient.IO_ERROR (Read timed out) (cause: java.net.SocketTimeoutException Read timed out)

I tried to optimize java in zimbra, but it doesn't work for me either.

too I tried this viewtopic.php?t=62378

my version of Zimbra: Release 8.8.15_GA_3869.RHEL7_64_20190917004220 RHEL7_64 FOSS edition, Patch 8.8.15_P2

any idea? suggestion?
rickygm
Posts: 19
Joined: Sat Sep 13, 2014 1:48 am

Re: java.net.SocketTimeoutException Read timed out

Post by rickygm »

Hi, try the latest version available, where I read that they fixed a large backup problem https://wiki.zimbra.com/wiki/Zimbra_Releases/8.8.15/P3 , but it doesn't work either.

my version of Zimbra: Release 8.8.15_GA_3869.RHEL7_64_20190917004220 RHEL7_64 FOSS edition, Patch 8.8.15_P3.

Server CentOS Linux release 7.7.1908 (Core)

server spec: 4GB RAM , 2 cores , ssd disk

backup size: 1.4gb per account
phoenix
Ambassador
Ambassador
Posts: 27278
Joined: Fri Sep 12, 2014 9:56 pm
Location: Liverpool, England

Re: java.net.SocketTimeoutException Read timed out

Post by phoenix »

The first thing I'd suggest is that you increase the installed RAM as you're fifty per-cent below the recommended minimum.
Regards

Bill

Rspamd: A high performance spamassassin replacement

Per ardua ad astra
AntoineM
Posts: 1
Joined: Thu Oct 31, 2019 10:19 am

Re: java.net.SocketTimeoutException Read timed out

Post by AntoineM »

Hello,

I have the same problem after upgrage from 8.6 to 8.8.15 P3.

I did not try to migrate account, the problem appeared with zmbackup and zmrestore (standard/classic tools, not using ng backup or zextra)

The only error message I get is :
Error occurred: Read timed out
Nothing in mailbox.log

I do not know what timeout to increase.
npoctotehb
Posts: 3
Joined: Wed Oct 03, 2018 2:23 pm

Re: java.net.SocketTimeoutException Read timed out

Post by npoctotehb »

Hello, got same problem...

Zimbra Collaboration 8.8.15_GA_3894.FOSS Patch 5
CPU 16 cores
16GB RAM

tryed to restore mailbox - /opt/zimbra/bin/zmmailbox -z -m $MailBox -t 0 postRestURL "//?fmt=tgz&resolve=replace" $Path/$Date/$MailBox
and got that error -
ERROR: zclient.IO_ERROR (Read timed out) (cause: java.net.SocketTimeoutException Read timed out)

-t 0 param been ignored, i think...

who's got answer|solution?
npoctotehb
Posts: 3
Joined: Wed Oct 03, 2018 2:23 pm

Re: java.net.SocketTimeoutException Read timed out

Post by npoctotehb »

If it helps someone.
I did full uninstall of zimbra.
Then did zimbra clean install.
Before apply updates and any zimbra configs,
i did run restore /opt/zimbra/bin/zmmailbox -z -m $MailBox -t 0 postRestURL "//?fmt=tgz&resolve=replace" $Path/$Date/$MailBox
and it work good, and have no errors!
Some mailboxes sizes is more than 50GB and they restored perfect!

That's link for version of zimbra that i installed
https://drive.google.com/file/d/1rqyiUu ... sp=sharing
Version is - zcs-8.8.15_GA_3869.UBUNTU18_64.20190918
After restore i did all updates and apply configurates.
All work!)
originalcris
Posts: 1
Joined: Fri Feb 21, 2020 4:33 pm

Re: java.net.SocketTimeoutException Read timed out

Post by originalcris »

This is a solution using curl:

1. Install curl (root):
yum install curl

2. Change to Zimbra:
su - zimbra

3. To restore only one user's tgz:
curl -k -u your_username:your_password --data-binary @/directory_backup_tgz/your_account_backup.tgz "https://localhost:7071/service/home/you ... solve=skip"

Good luck!!!
Sorry my english is not good.
User avatar
gabrieles
Outstanding Member
Outstanding Member
Posts: 236
Joined: Tue Feb 14, 2017 9:40 am

Re: java.net.SocketTimeoutException Read timed out

Post by gabrieles »

I fought with that "read time out" for some months, but related to zmmboxmove.
P7 should have fixed that:
https://wiki.zimbra.com/wiki/Zimbra_Releases/8.8.15/P7
Try to see if it fix even gru/pru mailbox moving
User avatar
evilside
Advanced member
Advanced member
Posts: 62
Joined: Sat Sep 13, 2014 3:24 am
Location: Chile
ZCS/ZD Version: zcs-8.8.15_GA_3918.UBUNTU14_64

Re: java.net.SocketTimeoutException Read timed out

Post by evilside »

gabrieles wrote:I fought with that "read time out" for some months, but related to zmmboxmove.
P7 should have fixed that:
https://wiki.zimbra.com/wiki/Zimbra_Releases/8.8.15/P7
Try to see if it fix even gru/pru mailbox moving
Noop. I have version 8.835.3963 and problem persist.
originalcris wrote: This is a solution using curl:

1. Install curl (root):
yum install curl

2. Change to Zimbra:
su - zimbra

3. To restore only one user's tgz:
curl -k -u your_username:your_password --data-binary @/directory_backup_tgz/your_account_backup.tgz "https://localhost:7071/service/home/you ... solve=skip"

Good luck!!!
Sorry my english is not good.
Not working to me, out memory error. :-(

"Curl: option --data-binary: out of memory".

But... I changed somethings and... It's working! Thanks very much originalcris

Code: Select all

curl -k -H "Transfer-Encoding: chunked" -u admin:AdminPassword -T /directory_backup_tgz/your_username@your_domain.com.tgz -X POST "https://InterfaceIP:9071/service/home/your_username@your_domain.com/?fmt=tgz&resolve=skip"
juan_urtiaga
Posts: 9
Joined: Mon Jan 23, 2017 7:44 pm

Re: java.net.SocketTimeoutException Read timed out

Post by juan_urtiaga »

Hi everyone.

I faced the same problem and I did not find a simple solution but reinstalling worked.

In my case I was testing and Upgrade & Migration procedure in a TEST enviroment where I had installed several versions of zimbra : 9.0 NE Beta, 9.0 Stable and finally 8.8.15 Open Source Edition. More precisely Release 8.8.15_GA_4362.RHEL8_64_20220721104405 RHEL8_64 FOSS edition, Patch 8.8.15_P33.

And during the import process the command:

zmmailbox -z -m $account -t 0 --verbose postRestURL "/?fmt=tgz&resolve=skip" $BACKUP_FOLDER/$account.tgz

Used to fail with ERROR: zclient.IO_ERROR (Read timed out) (cause: java.net.SocketTimeoutException Read timed out) with mailboxes greater than 1 GB or even smaller.
Note: the "-t 0" options did not change the behavior . And the curl command was worst because it gave no error but the import process was incomplete in mailbox "with problems"

So I choosed to do a new install (OS + ZIMBRA) using the definitive version and finally the zmmailbox command worked ok for every mailbox.
Offcourse In my case I could do it because its a new install but I know this could not apply to most of the scenarios so it would be great understand the root couse of the problem and find a more eficently solution.

Moreover at the end to be sure all mails were imported during the migration process I´ve add a simple registry at the export and import process to compare every mailbox:

ZM=`zmmailbox -z -m $account << EOF
quit
EOF`
NUMBER=`echo $ZM | awk '{print $4}' | cut -d ',' -f1`
UNIT=`echo $ZM | awk '{print $5}' | cut -d ',' -f1`
SIZE="$NUMBER$UNIT"
MSGS=`echo $ZM | awk '{print $7}' | cut -d ',' -f1`
echo $account $MSGS $SIZE >> VERIF_FILEE


[zimbra@mail logs]$ cat $VERIF_FILE
#account cant_msjs size

Regards,
Juan
Post Reply