[asterisk-bugs] [JIRA] (ASTERISK-22278) changemonitor returns WARNING[18526]: file.c:1229 ast_writefile permission denied when there is a permission
Walter Doekes (JIRA)
noreply at issues.asterisk.org
Mon Aug 19 03:33:03 CDT 2013
[ https://issues.asterisk.org/jira/browse/ASTERISK-22278?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=209289#comment-209289 ]
Walter Doekes commented on ASTERISK-22278:
------------------------------------------
Well. Asterisk doesn't make up those errors.
- are you sure you were running asterisk as root? check "ps faxu" output.
- are you running chrooted? in that case the directory may not exist where you expect it to be.
- did you check if the file was writable when asterisk was still running? (perhaps you have init scripts that mangle path permission / layout. all directories leading up to the file must have o+x permissions)
- don't symlink the /var/spool/asterisk/monitor directory. just configure that, or better yet, /tmp as the monitor dir and check what happens
- try this for more info:
{noformat}
--- main/file.c (revision 396920)
+++ main/file.c (working copy)
@@ -1154,6 +1154,8 @@
close(fd);
fd = -1;
}
+ } else {
+ ast_log(LOG_WARNING, "open(%s, %u|%u, %u) failed: %d/%s\n", fn, flags, myflags, mode, errno, strerror(errno));
}
if (ast_opt_cache_record_files && (fd > -1)) {
{noformat}
> changemonitor returns WARNING[18526]: file.c:1229 ast_writefile permission denied when there is a permission
> -------------------------------------------------------------------------------------------------------------
>
> Key: ASTERISK-22278
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-22278
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Applications/app_record
> Affects Versions: 11.5.0
> Environment: centos 6
> 2.6.32-358.el6.x86_64 #1 SMP Fri Feb 22 00:31:26 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
> Reporter: Ido Kanner
> Assignee: Ido Kanner
>
> When trying to use changemonitor in manager, asterisk reports the following:
> Aug 11 12:32:44] WARNING[18526]: file.c:1229 ast_writefile: Unable to open file /var/punchblock/record/2de73925-a752-4795-b9c2-2867ac6512c2-in.wav: Permission denied
> [Aug 11 12:32:44] WARNING[18526]: res_monitor.c:363 __ast_monitor_start: Could not create file /var/punchblock/record/2de73925-a752-4795-b9c2-2867ac6512c2-in
> [Aug 11 12:32:44] WARNING[18526]: res_monitor.c:633 __ast_monitor_change_fname: Cannot change monitor filename of channel SIP/support-00000004 to /var/punchblock/record/2de73925-a752-4795-b9c2-2867ac6512c2, monitoring not started
>
> I tried running asterisk as root, and not as the user asterisk with the same result.
> The /var/punchblock/record exists, and have the asterisk permissions.
> I even symlinked /var/spool/asterisk/monitor as the record directory just as I might be missing something, but nothing.
>
> My code (using adhearsion):
> record(async: true) do |event|
> @rec = event.recording.uri
> logger.info "Started recording at #{@rec}"
> end
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.asterisk.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the asterisk-bugs
mailing list