From: "budiljak (Benjamin Udiljak) via ruby-core" Date: 2024-05-04T14:59:10+00:00 Subject: [ruby-core:117774] [Ruby master Bug#20471] Problem creating a file on a windows share and copy it afterwards Issue #20471 has been reported by budiljak (Benjamin Udiljak). ---------------------------------------- Bug #20471: Problem creating a file on a windows share and copy it afterwards https://bugs.ruby-lang.org/issues/20471 * Author: budiljak (Benjamin Udiljak) * Status: Open * Backport: 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN ---------------------------------------- Hi, in my Rails application I have the requirement to create a file and copy it to another place on the same windows share. But if I write the file with `File` class and try to copy it with `FileUtils.cp` it hangs indefinitely without any error message. I can't even kill the ruby process. You can easily reproduce the bug by entering this in IRB: ``` filename = "/mnt/windows_share/abc"; File.open(filename, 'wb') { |f| f.write("123" * 1000) }; FileUtils.cp(filename, filename + "d") ``` I tested this on a Ubuntu 22.04 server in the AWS cloud. I also tried `f.fsync` , `f.fdatasync` , `f.flush`, but it didn't help. Probably it's a problem in connection with the `cifs-utils` package. Please come back to me if you need further information. Regards! Ben -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/