* fio: when not using a job file, timeouts are not applied @ 2011-07-18 19:01 Daniel Farina 2011-07-18 19:35 ` Chris Worley 0 siblings, 1 reply; 11+ messages in thread From: Daniel Farina @ 2011-07-18 19:01 UTC (permalink / raw) To: fio Hello list, Recently I found a bug whereby when when the --timeout option is utilized yet one does not use a job file (instead packing all the jobs into the arguments to fio) that timeouts to not work in fio 1.55. Having poked around via gdb it does appear the step whereby the timeout is propagated throughout the program does not occur when there are precisely 0 job files. Let me know if I can help with additional details, or it is thought that I am in error. Thanks, fdr ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 19:01 fio: when not using a job file, timeouts are not applied Daniel Farina @ 2011-07-18 19:35 ` Chris Worley 2011-07-18 21:46 ` Daniel Farina 0 siblings, 1 reply; 11+ messages in thread From: Chris Worley @ 2011-07-18 19:35 UTC (permalink / raw) To: Daniel Farina; +Cc: fio Can we see your fio command? I never use job files, and always use timeouts successfully. Chris On Mon, Jul 18, 2011 at 1:01 PM, Daniel Farina <daniel@heroku.com> wrote: > > Hello list, > > Recently I found a bug whereby when when the --timeout option is > utilized yet one does not use a job file (instead packing all the jobs > into the arguments to fio) that timeouts to not work in fio 1.55. > Having poked around via gdb it does appear the step whereby the > timeout is propagated throughout the program does not occur when there > are precisely 0 job files. > > Let me know if I can help with additional details, or it is thought > that I am in error. > > Thanks, > fdr > -- > To unsubscribe from this list: send the line "unsubscribe fio" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at �http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 19:35 ` Chris Worley @ 2011-07-18 21:46 ` Daniel Farina 2011-07-18 23:11 ` Chris Worley 0 siblings, 1 reply; 11+ messages in thread From: Daniel Farina @ 2011-07-18 21:46 UTC (permalink / raw) To: Chris Worley; +Cc: fio On Mon, Jul 18, 2011 at 12:35 PM, Chris Worley <worleys@gmail.com> wrote: > Can we see your fio command? �I never use job files, and always use > timeouts successfully. Absolutely: # Doesn't terminate for "quite a while" (I wasn't willing to wait) time sudo fio --readonly --minimal --norandommap --timeout=5 -name=/dev/sda1 --rw=randread --size=1GB --direct=1 --filename=/dev/sda1 With a jobfile called jobs.fio: [/dev/sda1] rw=randread size=1GB filename=/dev/sda1 direct=1 Everything is great: time sudo fio --readonly --minimal --norandommap --timeout=5 jobs.fio fio 1.55 2;/dev/sda1;0;0;41820;8563;5001;0;0;0.000000;0.000000;322;90574;460.528551;1378.863841;322;90575;461.305308;1378.867201;6880;9232;101.283584%;8469.333333;915.606903;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;4.000000%;0.000000%;10467;0;35;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;95.88%;3.25%;0.60%;0.17%;0.05%;0.02%;0.00%;0.00%;0.03%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% real 0m5.288s user 0m0.200s sys 0m0.150s -- fdr ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 21:46 ` Daniel Farina @ 2011-07-18 23:11 ` Chris Worley 2011-07-18 23:28 ` Daniel Farina 0 siblings, 1 reply; 11+ messages in thread From: Chris Worley @ 2011-07-18 23:11 UTC (permalink / raw) To: Daniel Farina; +Cc: fio On Mon, Jul 18, 2011 at 3:46 PM, Daniel Farina <daniel@heroku.com> wrote: > On Mon, Jul 18, 2011 at 12:35 PM, Chris Worley <worleys@gmail.com> wrote: >> Can we see your fio command? �I never use job files, and always use >> timeouts successfully. > > Absolutely: > > # Doesn't terminate for "quite a while" (I wasn't willing to wait) > time sudo fio --readonly --minimal --norandommap --timeout=5 > -name=/dev/sda1 --rw=randread --size=1GB --direct=1 Is that a single dash prior to "name"? Chris > --filename=/dev/sda1 > > With a jobfile called jobs.fio: > > [/dev/sda1] > rw=randread > size=1GB > filename=/dev/sda1 > direct=1 > > Everything is great: > > time sudo fio --readonly --minimal --norandommap --timeout=5 jobs.fio > fio 1.55 > 2;/dev/sda1;0;0;41820;8563;5001;0;0;0.000000;0.000000;322;90574;460.528551;1378.863841;322;90575;461.305308;1378.867201;6880;9232;101.283584%;8469.333333;915.606903;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;4.000000%;0.000000%;10467;0;35;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;95.88%;3.25%;0.60%;0.17%;0.05%;0.02%;0.00%;0.00%;0.03%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% > > > real � �0m5.288s > user � �0m0.200s > sys � � 0m0.150s > > > -- > fdr > ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 23:11 ` Chris Worley @ 2011-07-18 23:28 ` Daniel Farina 2011-07-18 23:49 ` Chris Worley 0 siblings, 1 reply; 11+ messages in thread From: Daniel Farina @ 2011-07-18 23:28 UTC (permalink / raw) To: Chris Worley; +Cc: fio On Mon, Jul 18, 2011 at 4:11 PM, Chris Worley <worleys@gmail.com> wrote: > On Mon, Jul 18, 2011 at 3:46 PM, Daniel Farina <daniel@heroku.com> wrote: >> On Mon, Jul 18, 2011 at 12:35 PM, Chris Worley <worleys@gmail.com> wrote: >>> Can we see your fio command? �I never use job files, and always use >>> timeouts successfully. >> >> Absolutely: >> >> # Doesn't terminate for "quite a while" (I wasn't willing to wait) >> time sudo fio --readonly --minimal --norandommap --timeout=5 >> -name=/dev/sda1 --rw=randread --size=1GB --direct=1 > > Is that a single dash prior to "name"? Yes, although that could be due to some sort of oopsie on my part. It doesn't seem to matter (seen here with a small amount of data, hence timeout does not come into play): $ time sudo fio --readonly --minimal --norandommap --timeout=5 -name=/dev/sda1 --rw=randread --size=256k --direct=1 --filename=/dev/sda1 fio 1.55 2;/dev/sda1;0;0;256;529;495;0;0;0.000000;0.000000;366;14021;799.359375;1701.445859;367;14023;799.984375;1701.600223;0;0;0.000000%;0.000000;0.000000;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;2.024291%;0.000000%;76;0;30;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;35.94%;57.81%;1.56%;1.56%;1.56%;0.00%;1.56%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% real 0m0.749s user 0m0.030s sys 0m0.100s $ time sudo fio --readonly --minimal --norandommap --timeout=5 --name=/dev/sda1 --rw=randread --size=256k --direct=1 --filename=/dev/sda1 fio 1.55 2;/dev/sda1;0;0;256;655;400;0;0;0.000000;0.000000;407;568;435.375000;21.859218;408;570;435.984375;21.941837;0;0;0.000000%;0.000000;0.000000;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;2.506266%;0.000000%;78;0;30;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;98.44%;1.56%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% real 0m0.679s user 0m0.010s sys 0m0.150s -- fdr ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 23:28 ` Daniel Farina @ 2011-07-18 23:49 ` Chris Worley 2011-07-19 0:02 ` Daniel Farina 0 siblings, 1 reply; 11+ messages in thread From: Chris Worley @ 2011-07-18 23:49 UTC (permalink / raw) To: Daniel Farina; +Cc: fio Could you add-in "--loops=10000"? On Mon, Jul 18, 2011 at 5:28 PM, Daniel Farina <daniel@heroku.com> wrote: > On Mon, Jul 18, 2011 at 4:11 PM, Chris Worley <worleys@gmail.com> wrote: >> On Mon, Jul 18, 2011 at 3:46 PM, Daniel Farina <daniel@heroku.com> wrote: >>> On Mon, Jul 18, 2011 at 12:35 PM, Chris Worley <worleys@gmail.com> wrote: >>>> Can we see your fio command? �I never use job files, and always use >>>> timeouts successfully. >>> >>> Absolutely: >>> >>> # Doesn't terminate for "quite a while" (I wasn't willing to wait) >>> time sudo fio --readonly --minimal --norandommap --timeout=5 >>> -name=/dev/sda1 --rw=randread --size=1GB --direct=1 >> >> Is that a single dash prior to "name"? > > Yes, although that could be due to some sort of oopsie on my part. �It > doesn't seem to matter (seen here with a small amount of data, hence > timeout does not come into play): > > $ time sudo fio --readonly --minimal --norandommap --timeout=5 > -name=/dev/sda1 --rw=randread --size=256k --direct=1 > --filename=/dev/sda1 > fio 1.55 > 2;/dev/sda1;0;0;256;529;495;0;0;0.000000;0.000000;366;14021;799.359375;1701.445859;367;14023;799.984375;1701.600223;0;0;0.000000%;0.000000;0.000000;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;2.024291%;0.000000%;76;0;30;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;35.94%;57.81%;1.56%;1.56%;1.56%;0.00%;1.56%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% > > > real � �0m0.749s > user � �0m0.030s > sys � � 0m0.100s > > $ time sudo fio --readonly --minimal --norandommap --timeout=5 > --name=/dev/sda1 --rw=randread --size=256k --direct=1 > --filename=/dev/sda1 > fio 1.55 > 2;/dev/sda1;0;0;256;655;400;0;0;0.000000;0.000000;407;568;435.375000;21.859218;408;570;435.984375;21.941837;0;0;0.000000%;0.000000;0.000000;0;0;0;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000;0.000000;0;0;0.000000%;0.000000;0.000000;2.506266%;0.000000%;78;0;30;100.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.0%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;98.44%;1.56%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00%;0.00% > real � �0m0.679s > user � �0m0.010s > sys � � 0m0.150s > > > -- > fdr > ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-18 23:49 ` Chris Worley @ 2011-07-19 0:02 ` Daniel Farina 2011-07-19 0:19 ` Chris Worley 0 siblings, 1 reply; 11+ messages in thread From: Daniel Farina @ 2011-07-19 0:02 UTC (permalink / raw) To: Chris Worley; +Cc: fio On Mon, Jul 18, 2011 at 4:49 PM, Chris Worley <worleys@gmail.com> wrote: > Could you add-in "--loops=10000"? No timeout occurs. FYI, I have poked around at init.c, and feel that somehow fill_def_thread isn't doing its job when job files are not being used: int parse_options(int argc, char *argv[]) { int job_files, i; f_out = stdout; f_err = stderr; fio_options_fill_optstring(); fio_options_dup_and_init(l_opts); if (setup_thread_area()) return 1; if (fill_def_thread()) return 1; job_files = parse_cmd_line(argc, argv); for (i = 0; i < job_files; i++) { if (fill_def_thread()) return 1; if (parse_jobs_ini(ini_file[i], i)) return 1; free(ini_file[i]); } I think something is fishy here with the order of events (see parse_cmd_line, which interprets the timeout, but fill_def_thread is not called after that point unless there are job files). gdb seemed to confirm that the value wasn't getting copied to the thread-local memory. (I also did try the non-forked based backend to make sure it wasn't some mechanism problem there, if memory serves). -- fdr ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-19 0:02 ` Daniel Farina @ 2011-07-19 0:19 ` Chris Worley 2011-07-19 0:21 ` Daniel Farina 2011-07-19 0:22 ` Chris Worley 0 siblings, 2 replies; 11+ messages in thread From: Chris Worley @ 2011-07-19 0:19 UTC (permalink / raw) To: Daniel Farina; +Cc: fio Do you mean to be using --timeout or --runtime? On Mon, Jul 18, 2011 at 6:02 PM, Daniel Farina <daniel@heroku.com> wrote: > On Mon, Jul 18, 2011 at 4:49 PM, Chris Worley <worleys@gmail.com> wrote: >> Could you add-in "--loops=10000"? > > No timeout occurs. > > FYI, I have poked around at init.c, and feel that somehow > fill_def_thread isn't doing its job when job files are not being used: > > int parse_options(int argc, char *argv[]) > { > � � � �int job_files, i; > > � � � �f_out = stdout; > � � � �f_err = stderr; > > � � � �fio_options_fill_optstring(); > � � � �fio_options_dup_and_init(l_opts); > > � � � �if (setup_thread_area()) > � � � � � � � �return 1; > � � � �if (fill_def_thread()) > � � � � � � � �return 1; > > � � � �job_files = parse_cmd_line(argc, argv); > > � � � �for (i = 0; i < job_files; i++) { > � � � � � � � �if (fill_def_thread()) > � � � � � � � � � � � �return 1; > � � � � � � � �if (parse_jobs_ini(ini_file[i], i)) > � � � � � � � � � � � �return 1; > � � � � � � � �free(ini_file[i]); > � � � �} > > I think something is fishy here with the order of events (see > parse_cmd_line, which interprets the timeout, but fill_def_thread is > not called after that point unless there are job files). gdb seemed to > confirm that the value wasn't getting copied to the thread-local > memory. �(I also did try the non-forked based backend to make sure it > wasn't some mechanism problem there, if memory serves). > > -- > fdr > ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-19 0:19 ` Chris Worley @ 2011-07-19 0:21 ` Daniel Farina 2011-07-23 11:43 ` Jens Axboe 2011-07-19 0:22 ` Chris Worley 1 sibling, 1 reply; 11+ messages in thread From: Daniel Farina @ 2011-07-19 0:21 UTC (permalink / raw) To: Chris Worley; +Cc: fio On Mon, Jul 18, 2011 at 5:19 PM, Chris Worley <worleys@gmail.com> wrote: > Do you mean to be using --timeout or --runtime? --timeout. It's pretty clear the semantics using a job file and those without a job file are not the same, or are you not able to reproduce this? -- fdr ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-19 0:21 ` Daniel Farina @ 2011-07-23 11:43 ` Jens Axboe 0 siblings, 0 replies; 11+ messages in thread From: Jens Axboe @ 2011-07-23 11:43 UTC (permalink / raw) To: Daniel Farina; +Cc: Chris Worley, fio On 2011-07-19 02:21, Daniel Farina wrote: > On Mon, Jul 18, 2011 at 5:19 PM, Chris Worley <worleys@gmail.com> wrote: >> Do you mean to be using --timeout or --runtime? > > --timeout. It's pretty clear the semantics using a job file and those > without a job file are not the same, or are you not able to reproduce > this? Sorry for the late reply, I'm on vacation. This should fix it. diff --git a/init.c b/init.c index 85bd0f7..98e10f7 100644 --- a/init.c +++ b/init.c @@ -47,7 +47,6 @@ int warnings_fatal = 0; int write_bw_log = 0; int read_only = 0; -static int def_timeout; static int write_lat_log; static int prev_group_jobs; @@ -951,8 +950,6 @@ static int fill_def_thread(void) * fill default options */ fio_fill_default_options(&def_thread); - - def_thread.o.timeout = def_timeout; return 0; } @@ -1160,7 +1157,7 @@ static int parse_cmd_line(int argc, char *argv[]) smalloc_pool_size = atoi(optarg); break; case 't': - def_timeout = atoi(optarg); + def_thread.o.timeout = atoi(optarg); break; case 'l': write_lat_log = 1; -- Jens Axboe ^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: fio: when not using a job file, timeouts are not applied 2011-07-19 0:19 ` Chris Worley 2011-07-19 0:21 ` Daniel Farina @ 2011-07-19 0:22 ` Chris Worley 1 sibling, 0 replies; 11+ messages in thread From: Chris Worley @ 2011-07-19 0:22 UTC (permalink / raw) To: Daniel Farina; +Cc: fio On Mon, Jul 18, 2011 at 6:19 PM, Chris Worley <worleys@gmail.com> wrote: > Do you mean to be using --timeout or --runtime? I should word that differently: it works fine using "runtime=5", "timeout=5" should work, but doesn't. Chris > > On Mon, Jul 18, 2011 at 6:02 PM, Daniel Farina <daniel@heroku.com> wrote: >> On Mon, Jul 18, 2011 at 4:49 PM, Chris Worley <worleys@gmail.com> wrote: >>> Could you add-in "--loops=10000"? >> >> No timeout occurs. >> >> FYI, I have poked around at init.c, and feel that somehow >> fill_def_thread isn't doing its job when job files are not being used: >> >> int parse_options(int argc, char *argv[]) >> { >> � � � �int job_files, i; >> >> � � � �f_out = stdout; >> � � � �f_err = stderr; >> >> � � � �fio_options_fill_optstring(); >> � � � �fio_options_dup_and_init(l_opts); >> >> � � � �if (setup_thread_area()) >> � � � � � � � �return 1; >> � � � �if (fill_def_thread()) >> � � � � � � � �return 1; >> >> � � � �job_files = parse_cmd_line(argc, argv); >> >> � � � �for (i = 0; i < job_files; i++) { >> � � � � � � � �if (fill_def_thread()) >> � � � � � � � � � � � �return 1; >> � � � � � � � �if (parse_jobs_ini(ini_file[i], i)) >> � � � � � � � � � � � �return 1; >> � � � � � � � �free(ini_file[i]); >> � � � �} >> >> I think something is fishy here with the order of events (see >> parse_cmd_line, which interprets the timeout, but fill_def_thread is >> not called after that point unless there are job files). gdb seemed to >> confirm that the value wasn't getting copied to the thread-local >> memory. �(I also did try the non-forked based backend to make sure it >> wasn't some mechanism problem there, if memory serves). >> >> -- >> fdr >> > ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2011-07-23 11:43 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-07-18 19:01 fio: when not using a job file, timeouts are not applied Daniel Farina 2011-07-18 19:35 ` Chris Worley 2011-07-18 21:46 ` Daniel Farina 2011-07-18 23:11 ` Chris Worley 2011-07-18 23:28 ` Daniel Farina 2011-07-18 23:49 ` Chris Worley 2011-07-19 0:02 ` Daniel Farina 2011-07-19 0:19 ` Chris Worley 2011-07-19 0:21 ` Daniel Farina 2011-07-23 11:43 ` Jens Axboe 2011-07-19 0:22 ` Chris Worley
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.