How long can it log data?

The TM-6430/1 is indefinitely. When set at a 1-minute interval, it will start to over-write old data after 1 year (but log data indefinitely). The TM-6440/1 is 2 years when set at a 1-minute interval. Increasing the interval will provide longer a longer data life.

Does the TM-4127 log data?

No. However, it does show high/low readings and meanwhile alarms can be set to signal out of range conditions.