svn - 无法在 AiX 7.2 机器上使用已编译的二进制文件(版本 1.10.2)创建 Subversion 存储库
问题描述
我们使用编译命令在 AiX 机器上编译了 subversion 1.10.2:-
./configure CFLAGS="-I/temp1110/subversion/zlib" --without-berkeley-db --with-apr=/temp1110/subversion/apr --with-apr-util=/temp1110/subversion/apr-util --with-lz4=internal --with-utf8proc=internal --disable-nls
而在使用“make”命令生成所需文件之后。我们无法创建存储库。通过命令后./svnadmin create /temp1110/home/Repo_test"
,我们得到错误:
svnadmin: E000009: 无法自动写入'/temp1110/home/Repo_test/db/current' svnadmin: E000009: 无法将文件'/temp1110/home/Repo_test/db' 刷新到磁盘:错误的文件号
知道如何解决这个问题吗?
解决方案
好吧,你无法解决这个问题,这是颠覆中的一个错误。
或者更确切地说是一个 AIX 特定的问题:fsync(2)
调用一个目录返回errno=EBADF
,这让人subverions/libsvn_subr/io.c:svn_io_flush_to_disk
很难过。
这可以通过以下补丁修复:
--- subversion/libsvn_subr/io.cold 2018-01-19 05:00:11.000000000 +0100
+++ subversion/libsvn_subr/io.c 2018-12-22 20:25:42.000000000 +0100
@@ -4286,7 +4286,13 @@
return svn_error_wrap_apr(status, _("Can't move '%s' to '%s'"),
svn_dirent_local_style(from_path, pool),
svn_dirent_local_style(to_path, pool));
-
+ #if !defined(_AIX)
+ /* on Aix, you cannot do fsync(2) on a directory,
+ also you cannot open a file for APR_WRITE
+ if its access bits are 444
+ Nonetheless this is a very useful peace of code,
+ just not for AIX.
+ */
#if defined(SVN_ON_POSIX)
if (flush_to_disk)
{
@@ -4314,7 +4320,7 @@
SVN_ERR(svn_io_file_close(file, pool));
}
#endif
-
+ #endif
return SVN_NO_ERROR;
}
推荐阅读
- tensorflow - TOCO 无法将 .pb 转换为 .tflite keras 的 ConverterError
- php - 来自数据库的图像不显示在网页上
- php - PHP Curl在浏览器上返回空字符串,在邮递员中工作
- python - 时间数据 2019-03-31T01:55:00CET 与指定的熊猫格式不匹配
- jquery - 从子元素更改 jQuery 对话框标题
- haskell - 是否有一个标准的 Haskell 函数,其类型为:(Floating a, RealFrac b) => a -> b?
- c# - 将访问令牌作为 URL 查询参数传递?
- c# - 用于 GCP KMS 非对称解密的 C# 加密示例
- uwp - 合成 - 为什么我的元素会立即在我的动画上设置模糊?
- html - 如何在导航菜单中添加按钮?