Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Owncloud 9.0.0 doesn't send notification emails #23205

Closed
matteociaschini opened this issue Mar 14, 2016 · 7 comments · Fixed by owncloud/activity#486
Closed

Owncloud 9.0.0 doesn't send notification emails #23205

matteociaschini opened this issue Mar 14, 2016 · 7 comments · Fixed by owncloud/activity#486

Comments

@matteociaschini
Copy link

Steps to reproduce

Owncloud 9 doesn't send notification emails

Expected behaviour

Cron script should periodically send notification emails

Actual behaviour

Notification emails are not sent and error on owncloud log is printed by EmailNotification app (see below owncloud error log).
Email configuration is correct (test email from admin page is working)
Problem start after updateing to owncloud 9.0.0

Server configuration

Operating system:
Ubuntu 14.04.4 LTS
Web server:
Apache/2.4.18
Database:
Mysql 5.7.11
PHP version:
5.6.19
ownCloud version: (see ownCloud admin page)
OwnCloud 9.0.0 (stable)
Updated from an older ownCloud or fresh install:
Update from 8.2.3
Where did you install ownCloud from:
https://download.owncloud.org/community/owncloud-9.0.0.zip
Signing status (ownCloud 9.0 and above):

No errors have been found.

List of activated apps:

Enabled:
  - activity: 2.2.1
  - comments: 0.2
  - dav: 0.1.5
  - federatedfilesharing: 0.1.0
  - federation: 0.0.4
  - files: 1.4.4
  - files_pdfviewer: 0.8
  - files_sharing: 0.9.1
  - files_texteditor: 2.1
  - files_videoplayer: 0.9.8
  - firstrunwizard: 1.1
  - gallery: 14.5.0
  - notifications: 0.2.3
  - provisioning_api: 0.4.1
  - systemtags: 0.2
  - templateeditor: 0.1
  - updatenotification: 0.1.0
  - user_ldap: 0.8.0
Disabled:
  - encryption
  - external
  - files_external
  - files_trashbin
  - files_versions
  - user_external

The content of config/config.php:

{
    "system": {
        "instanceid": "512d62f7bd397",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "datadirectory": "\/var\/www\/owncloud_data",
        "dbtype": "mysql",
        "dbname": "owncloud",
        "dbhost": "127.0.0.1",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "activity_expire_days": 7,
        "config_is_read_only": false,
        "installed": true,
        "loglevel": 3,
        "maintenance": false,
        "theme": "biesse",
        "log_type": "owncloud",
        "logdateformat": "F d, Y H:i:s",
        "logtimezone": "America\/New_York",
        "log_query": false,
        "log_rotate_size": 10485760,
        "trashbin_retention_obligation": 2,
        "trashbin_auto_expire": true,
        "mail_domain": "biesseamerica.com",
        "mail_smtpdebug": false,
        "mail_smtpmode": "smtp",
        "mail_smtphost": "biesseexcit.biesse.it",
        "mail_smtpport": "25",
        "mail_smtptimeout": 10,
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpauth": true,
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "trusted_domains": [
            "owncloud.biesseamerica.com"
        ],
        "version": "9.0.0.19",
        "mail_from_address": "it",
        "defaultapp": "files",
        "knowledgebaseenabled": true,
        "allow_user_to_change_display_name": true,
        "remember_login_cookie_lifetime": 1296000,
        "session_lifetime": 86400,
        "appstoreenabled": true,
        "appcodechecker": true,
        "updatechecker": true,
        "has_internet_connection": true,
        "check_for_working_webdav": true,
        "check_for_working_htaccess": true,
        "enable_previews": true,
        "preview_max_scale_factor": 10,
        "enable_avatars": true,
        "filesystem_check_changes": 0,
        "secret": "***REMOVED SENSITIVE VALUE***",
        "ldapUserCleanupInterval": 51,
        "preview_libreoffice_path": "\/usr\/bin\/libreoffice",
        "enabledPreviewProviders": [
            "OC\\Preview\\Image",
            "OC\\Preview\\MP3",
            "OC\\Preview\\TXT",
            "OC\\Preview\\MarkDown",
            "OC\\Preview\\Illustrator",
            "OC\\Preview\\Movie",
            "OC\\Preview\\MSOffice2003",
            "OC\\Preview\\MSOffice2007",
            "OC\\Preview\\MSOfficeDoc",
            "OC\\Preview\\OpenDocument",
            "OC\\Preview\\PDF",
            "OC\\Preview\\Photoshop",
            "OC\\Preview\\Postscript",
            "OC\\Preview\\StarOffice",
            "OC\\Preview\\SVG",
            "OC\\Preview\\TIFF"
        ]
    }
}

Are you using external storage, if yes which one: local/smb/sftp/...
No
Are you using encryption: yes/no
No
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...
LDAP

LDAP configuration (delete this part if not used)

user_ldap   bgjUpdateGroupsLastRun  1386957240
user_ldap   cleanUpJobOffset    1850
user_ldap   enabled yes
user_ldap   enforce_home_folder_naming_rule 
user_ldap   has_memberof_filter_support 1
user_ldap   home_folder_naming_rule 
user_ldap   installed_version   0.8.0
user_ldap   last_jpegPhoto_lookup   0
user_ldap   ldap_agent_password ***REMOVED SENSITIVE VALUE***
user_ldap   ldap_attributes_for_group_search    
user_ldap   ldap_attributes_for_user_search 
user_ldap   ldap_backup_host    
user_ldap   ldap_backup_port    389
user_ldap   ldap_base   OU=Biesse Global Network,DC=biesse,DC=it
user_ldap   ldap_base_groups    OU=Biesse Global Network,DC=biesse,DC=it
user_ldap   ldap_base_users OU=Biesse Global Network,DC=biesse,DC=it
user_ldap   ldap_cache_ttl  1
user_ldap   ldap_configuration_active   1
user_ldap   ldap_display_name   cn
user_ldap   ldap_dn ***REMOVED SENSITIVE VALUE***
user_ldap   ldap_dynamic_group_member_url   
user_ldap   ldap_email_attr mail
user_ldap   ldap_experienced_admin  1
user_ldap   ldap_expert_username_attr   sAMAccountName
user_ldap   ldap_expert_uuid_group_attr 
user_ldap   ldap_expert_uuid_user_attr  
user_ldap   ldap_group_display_name samaccountname
user_ldap   ldap_group_filter   (&(|(objectclass=top))(|(cn=CA01 Xtech)))
user_ldap   ldap_group_filter_mode  0
user_ldap   ldap_group_member_assoc_attribute   member
user_ldap   ldap_groupfilter_groups CA01 Xtech
user_ldap   ldap_groupfilter_objectclass    top
user_ldap   ldap_host   128.1.50.225
user_ldap   ldap_login_filter   (&(objectclass=user)(|(samaccountname=%uid)(|(sAMAccountName=%uid))))
user_ldap   ldap_login_filter_mode  1
user_ldap   ldap_loginfilter_attributes sAMAccountName
user_ldap   ldap_loginfilter_email  0
user_ldap   ldap_loginfilter_username   1
user_ldap   ldap_nested_groups  0
user_ldap   ldap_override_main_server   0
user_ldap   ldap_paging_size    500
user_ldap   ldap_port   389
user_ldap   ldap_quota_attr 
user_ldap   ldap_quota_def  
user_ldap   ldap_tls    0
user_ldap   ldap_turn_off_cert_check    1
user_ldap   ldap_user_display_name_2    
user_ldap   ldap_user_filter_mode   1
user_ldap   ldap_userfilter_groups  ALL Users Logged
 CA01 PC Admins
 CA01 Payables List
 CA01 Sales
 CA01 Sales Intermac Team
 CA01 Sales Team
 CA01 Salessupport
 CA01 Service
 CA01 XSalesToronto
 CA01 XTechWest
 CA01 XTorontoOffice
 CA01 XTorontoSales
 CA01 Xtech
 CA01 XtechMtl
 CA01 XtechToronto
 CA02...
user_ldap   ldap_userfilter_objectclass user
user_ldap   ldap_userlist_filter    objectclass=user
user_ldap   ldap_uuid_attribute objectguid
user_ldap   ldap_uuid_group_attribute   objectguid
user_ldap   ldap_uuid_user_attribute    objectguid
user_ldap   types   authentication
user_ldap   use_memberof_to_detect_membership   1

ownCloud log (data/owncloud.log)

{"reqId":"PxzifieNdMNJlQutDN2w","remoteAddr":"","app":"core","message":"Error while running background job (class: OCA\\Activity\\BackgroundJob\\EmailNotification, arguments: ): {\"Exception\":\"Exception\",\"Message\":\"Session has been closed - no further changes to the session are allowed\",\"Code\":0,\"Trace\":\"
#0 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/session\\\/memory.php(49): OC\\\\Session\\\\Memory->validateSession()\\n
#1 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/security\\\/csrf\\\/tokenstorage\\\/sessionstorage.php(63): OC\\\\Session\\\\Memory->set('requesttoken', 'vgCuoX6SQzpQ8c+...')\\n
#2 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/security\\\/csrf\\\/csrftokenmanager.php(57): OC\\\\Security\\\\CSRF\\\\TokenStorage\\\\SessionStorage->setToken('vgCuoX6SQzpQ8c+...')\\n
#3 \\\/var\\\/www\\\/owncloud\\\/lib\\\/public\\\/util.php(496): OC\\\\Security\\\\CSRF\\\\CsrfTokenManager->getToken()\\n
#4 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/template.php(75): OCP\\\\Util::callRegister()\\n
#5 \\\/var\\\/www\\\/owncloud\\\/apps\\\/activity\\\/lib\\\/mailqueuehandler.php(250): OC_Template->__construct('activity', 'email.notificat...', '')\\n
#6 \\\/var\\\/www\\\/owncloud\\\/apps\\\/activity\\\/lib\\\/backgroundjob\\\/emailnotification.php(134): OCA\\\\Activity\\\\MailQueueHandler->sendEmailToUser('CA01114', 'Matteo.Ciaschin...', 'en', 'America\\\/New_Yor...', 1457911801)\\n
#7 \\\/var\\\/www\\\/owncloud\\\/apps\\\/activity\\\/lib\\\/backgroundjob\\\/emailnotification.php(94): OCA\\\\Activity\\\\BackgroundJob\\\\EmailNotification->runStep(500, 1457911801)\\n
#8 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/backgroundjob\\\/job.php(52): OCA\\\\Activity\\\\BackgroundJob\\\\EmailNotification->run(NULL)\\n
#9 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/backgroundjob\\\/timedjob.php(53): OC\\\\BackgroundJob\\\\Job->execute(Object(OC\\\\BackgroundJob\\\\JobList), Object(OC\\\\Log))\\n
#10 \\\/var\\\/www\\\/owncloud\\\/cron.php(141): OC\\\\BackgroundJob\\\\TimedJob->execute(Object(OC\\\\BackgroundJob\\\\JobList), Object(OC\\\\Log))\\n#11 {main}\",\"File\":\"\\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/session\\\/memory.php\",\"Line\":105}","level":3,"time":"March 13, 2016 23:30:02"}
@StrannikST
Copy link

I confirm, email is not sent. The error logs.

@PVince81
Copy link
Contributor

@LukasReschke weird session issue with cron ?!

@PVince81
Copy link
Contributor

CC @nickvergessen for the activity part

@PVince81 PVince81 added this to the 9.0.1-current-maintenance milestone Mar 14, 2016
LukasReschke added a commit to owncloud/activity that referenced this issue Mar 14, 2016
The session is closed at this point since it may come over CLI => 💣

Fixes owncloud/core#23205
@LukasReschke
Copy link
Member

A proposed fix for this can be found at owncloud/activity#486, @matteociaschini @StrannikST could you test this as well? Thanks a lot! 🚀

nickvergessen pushed a commit to owncloud/activity that referenced this issue Mar 14, 2016
The session is closed at this point since it may come over CLI => 💣

Fixes owncloud/core#23205
@wasolu18
Copy link

I am not sure, but I think I am having same issue. when I try to share a file I get this error: Failed to send share by mail. the mail wont send. when I check log, I see this: no app in contex - Failed to send share by email: Address in mailbox given [myemail@] does not comply with RFC 2822, 3.6.2.
not sure where to fix. I have tried forcing by going into files and keying in email, but that don't work. still get error even though email shows up in userface.

@PVince81
Copy link
Contributor

does the domain name contain any special characters ?

as far as I remember it is possible that the Swiftmailer library validation doesn't properly recognize domain names with international characters, see #13586

@lock
Copy link

lock bot commented Jul 31, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jul 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants