V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  flewover  ›  全部回复第 1 页 / 共 2 页
回复总数  37
1  2  
办了香港的银行卡,可以买美股,也可以存美元、购买美债么?是不是一定程度上可以对冲人民币汇率大幅波动带来的风险
2023-01-13 15:29:46 +08:00
回复了 cveoy 创建的主题 程序员 搞技术的你们都写月报吗?
半周报,周报,季度总结,半年总结,年度总结
2022-12-18 18:49:33 +08:00
回复了 Features 创建的主题 程序员 有没有低成本异地容灾方案?
- 单看数据库的异地灾备,两地三中心,成本很高;一种高性价比方式是同城多 az ,异地有一个异步复制的 az ;但具体采用什么方案,要综合看一致性,RTO ,RPO 各项指标了。
- 应用层也有应用层的灾备;
2022-11-29 16:16:39 +08:00
回复了 bigxianyu 创建的主题 问与答 今天听朋友说裁员赔偿有 2n?
借楼问一下,如果基本工资是 A/月,裁员给 n+1 ,拿到手(税前)是 A*(n+1) 么?
网上看到有说如果 A 超过当地平均工资的 3 倍,上限是 3 * (当地平均月薪)* (n+1)。(这样岂不是很亏。。
有一个 MDR-XB950AP ,对应的有线版,确实还不错
@WildCat 看看权限?
2015-05-21 10:11:15 +08:00
回复了 flewover 创建的主题 程序员 在程序里禁用了 Nagle 算法还会出现 200ms 延迟么
@est 很有帮助 :)
@simomo2010 我再跟踪一下看个究竟
2015-05-20 23:58:21 +08:00
回复了 flewover 创建的主题 程序员 在程序里禁用了 Nagle 算法还会出现 200ms 延迟么
用 strace 查看了系统调用,接收端 200ms 出现在 epoll_wait

[<... epoll_wait resumed> {{EPOLLIN|EPOLLOUT, {u32=1626358040, u64=140674690203928}}}, 128, -1) = 1 <0.202147>
]

接收端日志:
2015-05-20 23:40:19.629 [INFO] 54f99 [processPushMsg] send 81 direct msg to connector conn0101 latency: 697548.524
2015-05-20 23:40:19.629 [DEBU] 54f9a [handleTCPConn] before get new bufio reader
2015-05-20 23:40:19.630 [DEBU] 54f9b [handleTCPConn] before read
2015-05-20 23:40:19.834 [DEBU] 54f9c [handleTCPConn] end read rlen: 4068
2015-05-20 23:40:19.834 [INFO] 54f9d [processPushMsg] send 39 direct msg to connector conn0101 latency: 697753.906


strace 日志(sudo strace -f -v -x -tt -T -p 92324 -o strace_recv.log):

94951 23:40:19.629828 write(3, "2015-05-20 23:40:19.629 [INFO] 5"..., 115) = 115 <0.000038>
94951 23:40:19.629958 clock_gettime(CLOCK_REALTIME, {1432136419, 629994695}) = 0 <0.000031>
94951 23:40:19.630103 clock_gettime(CLOCK_REALTIME, {1432136419, 630143536}) = 0 <0.000032>
94951 23:40:19.630219 write(3, "2015-05-20 23:40:19.629 [DEBU] 5"..., 81) = 81 <0.000036>
94951 23:40:19.630337 clock_gettime(CLOCK_REALTIME, {1432136419, 630373340}) = 0 <0.000030>
94951 23:40:19.630479 clock_gettime(CLOCK_REALTIME, {1432136419, 630518521}) = 0 <0.000031>
94951 23:40:19.630600 write(3, "2015-05-20 23:40:19.630 [DEBU] 5"..., 65) = 65 <0.000036>
94951 23:40:19.630717 read(9, 0xc20805f01c, 4068) = -1 EAGAIN (Resource temporarily unavailable) <0.000033>
94951 23:40:19.630833 write(8, "\x01\x03\xf1\x00\x01\x00\x0c\x55\x5c\xa8\x4d\x62\xbb\x97\x68\xde\x01\xd1\x12\x02\x00\x10\x31\x34\x33\x32\x31\x33\x35\x37\x32\x32"..., 1013) = 1013 <0.000103>
94951 23:40:19.631027 write(8, "\x01\x01\xf9\x00\x03\x01\xd4\x55\x5c\x9c\x2a\x62\xbb\x97\x68\x8c\x00\x02\xa9\x55\x5c\x9c\x2a\x62\xbb\x97\x68\x8c\x00\x02\xfc\x55"..., 509) = 509 <0.000067>
94951 23:40:19.631187 write(8, "\x01\x03\xf1\x00\x03\x03\xcc\x55\x5c\x9c\x29\x62\xbb\x97\x68\x8c\x00\x01\x3d\x55\x5c\x9c\x2a\x62\xbb\x97\x68\x8c\x00\x02\x93\x55"..., 1013) = 1013 <0.000058>
94951 23:40:19.631332 epoll_wait(6, {}, 128, 0) = 0 <0.000035>
94951 23:40:19.631440 epoll_wait(6, <unfinished ...>
92326 23:40:19.631496 <... futex resumed> ) = 0 <0.205872>
92326 23:40:19.631554 clock_gettime(CLOCK_MONOTONIC, {1298109, 942247030}) = 0 <0.000033>
92326 23:40:19.631664 clock_gettime(CLOCK_REALTIME, {1432136419, 631698624}) = 0 <0.000031>
92326 23:40:19.631767 select(0, NULL, NULL, NULL, {0, 20} <unfinished ...>
92324 23:40:19.631845 <... futex resumed> ) = 0 <0.206158>
92324 23:40:19.631911 epoll_wait(6, {}, 128, 0) = 0 <0.000064>
92326 23:40:19.632048 <... select resumed> ) = 0 (Timeout) <0.000248>
92326 23:40:19.632112 clock_gettime(CLOCK_MONOTONIC, {1298109, 942807377}) = 0 <0.000031>
92326 23:40:19.632215 futex(0x8f4de0, FUTEX_WAIT, 0, {60, 0} <unfinished ...>
92324 23:40:19.632279 futex(0x8f5838, FUTEX_WAIT, 0, NULL <unfinished ...>
94951 23:40:19.833623 <... epoll_wait resumed> {{EPOLLIN|EPOLLOUT, {u32=1626358040, u64=140674690203928}}}, 128, -1) = 1 <0.202147>
94951 23:40:19.833780 clock_gettime(CLOCK_MONOTONIC, {1298110, 144480859}) = 0 <0.000032>
94951 23:40:19.833902 futex(0x8f5838, FUTEX_WAKE, 1) = 1 <0.000044>
94951 23:40:19.834024 futex(0x8f4de0, FUTEX_WAKE, 1) = 1 <0.000042>
94951 23:40:19.834131 read(9, "\x5c\x9c\x29\x62\xbb\x97\x68\x8c\x00\x01\x56\x63\x6f\x6e\x6e\x30\x31\x30\x31\x55\x5c\x9c\x2a\x62\xbb\x97\x68\x8c\x00\x03\x24\x63"..., 4068) = 4068 <0.000039>
94951 23:40:19.834268 clock_gettime(CLOCK_REALTIME, {1432136419, 834305215}) = 0 <0.000030>
94951 23:40:19.834476 clock_gettime(CLOCK_REALTIME, {1432136419, 834519537}) = 0 <0.000033>
94951 23:40:19.834601 write(3, "2015-05-20 23:40:19.834 [DEBU] 5"..., 73) = 73 <0.000042>
94951 23:40:19.834778 clock_gettime(CLOCK_REALTIME, {1432136419, 834819514}) = 0 <0.000032>
94951 23:40:19.834896 clock_gettime(CLOCK_REALTIME, {1432136419, 834931088}) = 0 <0.000030>
94951 23:40:19.835061 clock_gettime(CLOCK_REALTIME, {1432136419, 835102950}) = 0 <0.000033>
94951 23:40:19.835180 write(3, "2015-05-20 23:40:19.834 [INFO] 5"..., 115) = 115 <0.000037>
2015-05-20 23:51:37 +08:00
回复了 flewover 创建的主题 程序员 在程序里禁用了 Nagle 算法还会出现 200ms 延迟么
@ryd994 说的禁用 Nagle 就是调用了 c.SetNoDelay(true)
2015-05-20 20:29:06 +08:00
回复了 flewover 创建的主题 程序员 在程序里禁用了 Nagle 算法还会出现 200ms 延迟么
@simomo2010

那两条日志确实是在 rlen, err := rd.Read(rbuf[:]) 的前后,但是这个 read 接口只调用一次 reader 的 read,产生延迟应该不是需要填满 buf 引发的。

// Read reads data into p.
// It returns the number of bytes read into p.
// It calls Read at most once on the underlying Reader,
// hence n may be less than len(p).
// At EOF, the count will be zero and err will be io.EOF.
func (b *Reader) Read(p []byte) (n int, err error) {
...
}
2015-05-20 18:56:53 +08:00
回复了 flewover 创建的主题 程序员 在程序里禁用了 Nagle 算法还会出现 200ms 延迟么
@zhicheng 模糊的知道一些概念,但是不知道具体与哪些内核参数相关,如何调优,请问有哪些监控指标可以反映网络拥塞状况?还是需要应用层做流量控制?
2015-04-24 13:52:28 +08:00
回复了 niuer 创建的主题 程序员 近十年来最好的语言是什么?-来 Gopher China 大会找答案
竟然有直播,刚刚从北京来到上海😓
2015-02-20 00:00:18 +08:00
回复了 ricorico 创建的主题 天黑以后 20150220 午夜俱乐部
睡觉前在 app store 发现了移植PC的三国志曹操传,小时候超喜欢的游戏,中毒了。。。
2015-01-05 12:39:19 +08:00
回复了 josephok 创建的主题 Linux errno 是如何实现线程安全的?
[Thread-safety and POSIX.1](http://www.unix.org/whitepapers/reentrant.html)

Redefinition of errno 那部分
2015-01-03 10:58:22 +08:00
回复了 flewover 创建的主题 问与答 电脑里多出一些 xxxxxxx.cmos.greencompute.org 的文件,求解
@SR1 谢谢你的认真回复

1. 这些文件是从 Safari 下载到用户Downloads 目录的。下载都是自动发生的,今天早上又出现了。期间浏览过的网站只有 V2EX,微博,新浪 NBA和虎扑篮球。

2. 前几天确实上过一次 http://mf.greencompute.org 这个网站。

3. 再继续观察了。
2014-11-02 18:19:49 +08:00
回复了 lmaq 创建的主题 V2EX 教育网最近无法访问 V2EX,求解决啊~
北京教育网前几天也发现这个问题,已经把 v2ex 加到 pac 列表里了= =
2014-10-30 16:30:09 +08:00
回复了 u 创建的主题 macOS Yosemite 用一段时间之后三指以上的触摸板手势就会失灵
每过两三天会遇到一次,注销就会解决,原因不明。
2014-10-20 17:54:31 +08:00
回复了 niuer 创建的主题 云计算 七牛三周年嘉年华 感恩有你
回复被折叠了 23
2014-10-20 17:51:52 +08:00
回复了 niuer 创建的主题 云计算 七牛三周年嘉年华 感恩有你
23
2014-09-22 14:22:54 +08:00
回复了 rainday 创建的主题 程序员 福利!花了两个月时间终于和妹纸做完了程序员最爱的网站
😄

yf1013882191 at gmail.com
1  2  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3158 人在线   最高记录 6543   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 44ms · UTC 12:43 · PVG 20:43 · LAX 05:43 · JFK 08:43
Developed with CodeLauncher
♥ Do have faith in what you're doing.